@@ -48,7 +48,7 @@ open class StatsServiceRemoteV2: ServiceRemoteWordPressComREST {
4848
4949 let path = self . path ( forEndpoint: " sites/ \( siteID) / \( pathComponent) / " , withVersion: . _1_1)
5050
51- wordPressComRestApi . GET ( path, parameters: properties, success: { ( response, _) in
51+ wordPressComRESTAPI . get ( path, parameters: properties, success: { ( response, _) in
5252 guard
5353 let jsonResponse = response as? [ String : AnyObject ] ,
5454 let insight = InsightType ( jsonDictionary: jsonResponse)
@@ -72,7 +72,7 @@ open class StatsServiceRemoteV2: ServiceRemoteWordPressComREST {
7272 success: @escaping ( ) -> Void ,
7373 failure: @escaping ( Error ) -> Void ) {
7474 let path = pathForToggleSpamStateEndpoint ( referrerDomain: referrerDomain, markAsSpam: !currentValue)
75- wordPressComRestApi . POST ( path, parameters: nil , success: { object, _ in
75+ wordPressComRESTAPI . post ( path, parameters: nil , success: { object, _ in
7676 guard
7777 let dictionary = object as? [ String : AnyObject ] ,
7878 let response = MarkAsSpamResponse ( dictionary: dictionary) else {
@@ -117,7 +117,7 @@ open class StatsServiceRemoteV2: ServiceRemoteWordPressComREST {
117117 return val1
118118 }
119119
120- wordPressComRestApi . GET ( path, parameters: properties, success: { [ weak self] ( response, _) in
120+ wordPressComRESTAPI . get ( path, parameters: properties, success: { [ weak self] ( response, _) in
121121 guard
122122 let self,
123123 let jsonResponse = response as? [ String : AnyObject ] ,
@@ -153,7 +153,7 @@ open class StatsServiceRemoteV2: ServiceRemoteWordPressComREST {
153153 public func getDetails( forPostID postID: Int , completion: @escaping ( ( StatsPostDetails ? , Error ? ) -> Void ) ) {
154154 let path = self . path ( forEndpoint: " sites/ \( siteID) /stats/post/ \( postID) / " , withVersion: . _1_1)
155155
156- wordPressComRestApi . GET ( path, parameters: [ : ] , success: { ( response, _) in
156+ wordPressComRESTAPI . get ( path, parameters: [ : ] , success: { ( response, _) in
157157 guard
158158 let jsonResponse = response as? [ String : AnyObject ] ,
159159 let postDetails = StatsPostDetails ( jsonDictionary: jsonResponse)
@@ -183,7 +183,7 @@ extension StatsServiceRemoteV2 {
183183 let pathComponent = StatsLastPostInsight . pathComponent
184184 let path = self . path ( forEndpoint: " sites/ \( siteID) / \( pathComponent) " , withVersion: . _1_1)
185185
186- wordPressComRestApi . GET ( path, parameters: properties, success: { ( response, _) in
186+ wordPressComRESTAPI . get ( path, parameters: properties, success: { ( response, _) in
187187 guard let jsonResponse = response as? [ String : AnyObject ] ,
188188 let postCount = jsonResponse [ " found " ] as? Int else {
189189 completion ( nil , ResponseError . decodingFailure)
@@ -224,7 +224,7 @@ extension StatsServiceRemoteV2 {
224224
225225 let path = self . path ( forEndpoint: " sites/ \( siteID) /stats/post/ \( postID) " , withVersion: . _1_1)
226226
227- wordPressComRestApi . GET ( path,
227+ wordPressComRESTAPI . get ( path,
228228 parameters: parameters,
229229 success: { ( response, _) in
230230 guard
@@ -259,7 +259,7 @@ extension StatsServiceRemoteV2 {
259259 " after " : ISO8601DateFormatter ( ) . string ( from: startDate ( for: period, endDate: endingOn) ) ,
260260 " before " : ISO8601DateFormatter ( ) . string ( from: endingOn) ] as [ String : AnyObject ]
261261
262- wordPressComRestApi . GET ( path,
262+ wordPressComRESTAPI . get ( path,
263263 parameters: properties,
264264 success: { ( response, _) in
265265 guard
0 commit comments