diff --git a/Project/Sources/Classes/GoogleUser.4dm b/Project/Sources/Classes/GoogleUser.4dm
index 44378ec..1fe58f1 100644
--- a/Project/Sources/Classes/GoogleUser.4dm
+++ b/Project/Sources/Classes/GoogleUser.4dm
@@ -26,7 +26,7 @@ Function _get($inResourceName : Text; $inPersonFields : Variant) : Object
End if
Case of
- : ((Type($inPersonFields)=Is collection) && ($inPersonFields.length>0))
+ : ((Value type($inPersonFields)=Is collection) && ($inPersonFields.length>0))
$personFields:=$inPersonFields.join(","; ck ignore null or empty)
: ((Value type($inPersonFields)=Is text) && (Length(String($inPersonFields))>0))
$personFields:=$inPersonFields
@@ -51,9 +51,9 @@ Function _getURLParamsFromObject($inParameters : Object) : Text
var $delimiter : Text:="?"
Case of
- : (OB Is defined($inParameters; "select") && (Type($inParameters.select)=Is collection) && ($inParameters.select.length>0))
+ : ((Value type($inParameters.select)=Is collection) && ($inParameters.select.length>0))
$personFields:=$inParameters.select.join(","; ck ignore null or empty)
- : (OB Is defined($inParameters; "select") && (Value type($inParameters.sources)=Is text) && (Length(String($inParameters.select))>0))
+ : ((Value type($inParameters.select)=Is text) && (Length(String($inParameters.select))>0))
$personFields:=$inParameters.select
Else
$personFields:=This._internals.defaultPersonFields.join(","; ck ignore null or empty)
@@ -62,9 +62,9 @@ Function _getURLParamsFromObject($inParameters : Object) : Text
$delimiter:="&"
Case of
- : (OB Is defined($inParameters; "sources") && (Value type($inParameters.sources)=Is collection) && ($inParameters.sources>0))
+ : ((Value type($inParameters.sources)=Is collection) && ($inParameters.sources>0))
$sources:=This._internals.defaultSources.join("&sources="; ck ignore null or empty)
- : (OB Is defined($inParameters; "sources") && (Value type($inParameters.sources)=Is text) && (Length(String($inParameters.sources))>0))
+ : ((Value type($inParameters.sources)=Is text) && (Length(String($inParameters.sources))>0))
$sources:=$inParameters.sources
Else
$sources:=This._internals.defaultSources.join("&sources="; ck ignore null or empty)
@@ -72,9 +72,9 @@ Function _getURLParamsFromObject($inParameters : Object) : Text
$urlParams+=($delimiter+"sources="+$sources)
Case of
- : (OB Is defined($inParameters; "mergedSources") && (Value type($inParameters.mergedSources)=Is collection) && ($inParameters.mergedSources>0))
+ : ((Value type($inParameters.mergedSources)=Is collection) && ($inParameters.mergedSources>0))
$urlParams+=($delimiter+"mergeSources="+This._internals.defaultSources.join("&mergeSources="; ck ignore null or empty))
- : (OB Is defined($inParameters; "mergedSources") && (Value type($inParameters.mergedSources)=Is text) && (Length(String($inParameters.mergedSources))>0))
+ : ((Value type($inParameters.mergedSources)=Is text) && (Length(String($inParameters.mergedSources))>0))
$urlParams+=($delimiter+"mergeSources="+$inParameters.mergedSources)
End case
@@ -121,8 +121,9 @@ Function get($inResourceName : Text; $inPersonFields : Variant) : Object
Function list($inParameters : Object) : Object
Super._clearErrorStack()
-
+
var $URL : Text:=Super._getURL()+"people:listDirectoryPeople"+This._getURLParamsFromObject($inParameters)
var $headers : Object:={Accept: "application/json"}
-
- return cs.GoogleUserList.new(This._getOAuth2Provider(); $URL; $headers)
+ var $requestSyncToken : Boolean:=OB Is defined($inParameters; "requestSyncToken") ? Bool($inParameters.requestSyncToken) : False
+
+ return cs.GoogleUserList.new(This._getOAuth2Provider(); $URL; $headers; $requestSyncToken)
diff --git a/Project/Sources/Classes/GoogleUserList.4dm b/Project/Sources/Classes/GoogleUserList.4dm
index 2a2751b..5b0506c 100644
--- a/Project/Sources/Classes/GoogleUserList.4dm
+++ b/Project/Sources/Classes/GoogleUserList.4dm
@@ -1,8 +1,8 @@
Class extends _GoogleBaseList
-Class constructor($inProvider : cs.OAuth2Provider; $inURL : Text; $inHeaders : Object)
+Class constructor($inProvider : cs.OAuth2Provider; $inURL : Text; $inHeaders : Object; $inRequestSyncToken : Boolean)
- Super($inProvider; $inURL; "people"; $inHeaders)
+ Super($inProvider; $inURL; "people"; $inHeaders; $inRequestSyncToken)
// Mark: - [Public]
diff --git a/Project/Sources/Classes/Tools.4dm b/Project/Sources/Classes/Tools.4dm
index 678db62..1734389 100644
--- a/Project/Sources/Classes/Tools.4dm
+++ b/Project/Sources/Classes/Tools.4dm
@@ -517,3 +517,12 @@ Function urlEncode($value : Text) : Text
End for
return $result
+
+
+ // ----------------------------------------------------
+
+
+Function localizedString($inValue : Text) : Text
+
+ /* Temp to avoid compilation issues due to command renaming */
+ return Localized string:C991($inValue)
diff --git a/Project/Sources/Classes/_BaseClass.4dm b/Project/Sources/Classes/_BaseClass.4dm
index 6df2b93..75e9229 100644
--- a/Project/Sources/Classes/_BaseClass.4dm
+++ b/Project/Sources/Classes/_BaseClass.4dm
@@ -2,7 +2,7 @@ property _internals : Object
Class constructor()
- This:C1470._internals:={_errorStack: Null:C1517; _throwErrors: True:C214; _savedErrorHandler: ""}
+ This._internals:={_errorStack: Null; _throwErrors: True; _savedErrorHandler: ""}
// Mark: - [Private]
@@ -12,21 +12,21 @@ Class constructor()
Function _pushError($inCode : Integer; $inParameters : Object) : Object
// Push error into errorStack without throwing it
- var $description : Text:=Localized string:C991("ERR_4DNK_"+String:C10($inCode))
+ var $description : Text:=cs.Tools.me.localizedString("ERR_4DNK_"+String($inCode))
- If (Not:C34(OB Is empty:C1297($inParameters)))
+ If (Not(OB Is empty($inParameters)))
var $key : Text
For each ($key; $inParameters)
- $description:=Replace string:C233($description; "{"+$key+"}"; String:C10($inParameters[$key]))
+ $description:=Replace string($description; "{"+$key+"}"; String($inParameters[$key]))
End for each
End if
// Push error into errorStack
var $error : Object:={errCode: $inCode; componentSignature: "4DNK"; message: $description}
- If (This:C1470._internals._errorStack=Null:C1517)
- This:C1470._internals._errorStack:=[]
+ If (This._internals._errorStack=Null)
+ This._internals._errorStack:=[]
End if
- This:C1470._internals._errorStack.push($error)
+ This._internals._errorStack.push($error)
return $error
@@ -37,11 +37,11 @@ Function _pushError($inCode : Integer; $inParameters : Object) : Object
Function _throwError($inCode : Integer; $inParameters : Object)
// Push error into errorStack and throw it
- var $error : Object:=This:C1470._pushError($inCode; $inParameters)
+ var $error : Object:=This._pushError($inCode; $inParameters)
- If (This:C1470._internals._throwErrors)
- $error.deferred:=True:C214
- throw:C1805($error)
+ If (This._internals._throwErrors)
+ $error.deferred:=True
+ throw($error)
End if
@@ -50,12 +50,12 @@ Function _throwError($inCode : Integer; $inParameters : Object)
Function _try
- CLEAR VARIABLE:C89(ERROR)
- CLEAR VARIABLE:C89(ERROR METHOD)
- CLEAR VARIABLE:C89(ERROR LINE)
- CLEAR VARIABLE:C89(ERROR FORMULA)
+ CLEAR VARIABLE(ERROR)
+ CLEAR VARIABLE(ERROR METHOD)
+ CLEAR VARIABLE(ERROR LINE)
+ CLEAR VARIABLE(ERROR FORMULA)
- ON ERR CALL:C155("_catch"; ek errors from components:K92:3)
+ ON ERR CALL("_catch"; ek errors from components)
// ----------------------------------------------------
@@ -63,7 +63,7 @@ Function _try
Function _finally
- ON ERR CALL:C155(This:C1470._internals._throwErrors ? "_throwError" : ""; ek errors from components:K92:3)
+ ON ERR CALL(This._internals._throwErrors ? "_throwError" : ""; ek errors from components)
// ----------------------------------------------------
@@ -71,10 +71,10 @@ Function _finally
Function _getErrorStack : Collection
- If (This:C1470._internals._errorStack=Null:C1517)
- This:C1470._internals._errorStack:=[]
+ If (This._internals._errorStack=Null)
+ This._internals._errorStack:=[]
End if
- return This:C1470._internals._errorStack
+ return This._internals._errorStack
// ----------------------------------------------------
@@ -82,10 +82,10 @@ Function _getErrorStack : Collection
Function _getLastError : Object
- If (This:C1470._getErrorStack().length>0)
- return This:C1470._getErrorStack().last()
+ If (This._getErrorStack().length>0)
+ return This._getErrorStack().last()
End if
- return Null:C1517
+ return Null
// ----------------------------------------------------
@@ -93,7 +93,7 @@ Function _getLastError : Object
Function _getLastErrorCode : Integer
- return Num:C11(This:C1470._getLastError().errCode)
+ return Num(This._getLastError().errCode)
// ----------------------------------------------------
@@ -101,7 +101,7 @@ Function _getLastErrorCode : Integer
Function _clearErrorStack
- This:C1470._getErrorStack().clear()
+ This._getErrorStack().clear()
// ----------------------------------------------------
@@ -109,13 +109,13 @@ Function _clearErrorStack
Function _throwErrors($inThrowErrors : Boolean)
- If (Bool:C1537($inThrowErrors))
- This:C1470._internals._throwErrors:=True:C214
- This:C1470._resetErrorHandler()
+ If (Bool($inThrowErrors))
+ This._internals._throwErrors:=True
+ This._resetErrorHandler()
Else
- This:C1470._installErrorHandler()
- This:C1470._internals._throwErrors:=False:C215
- This:C1470._getErrorStack().clear()
+ This._installErrorHandler()
+ This._internals._throwErrors:=False
+ This._getErrorStack().clear()
End if
@@ -124,8 +124,8 @@ Function _throwErrors($inThrowErrors : Boolean)
Function _installErrorHandler($inErrorHandler : Text)
- This:C1470._internals._savedErrorHandler:=Method called on error:C704
- ON ERR CALL:C155((Length:C16($inErrorHandler)>0) ? $inErrorHandler : "_errorHandler"; ek errors from components:K92:3)
+ This._internals._savedErrorHandler:=Method called on error
+ ON ERR CALL((Length($inErrorHandler)>0) ? $inErrorHandler : "_errorHandler"; ek errors from components)
// ----------------------------------------------------
@@ -133,6 +133,5 @@ Function _installErrorHandler($inErrorHandler : Text)
Function _resetErrorHandler
- ON ERR CALL:C155(This:C1470._internals._savedErrorHandler; ek errors from components:K92:3)
- This:C1470._internals._savedErrorHandler:=""
-
\ No newline at end of file
+ ON ERR CALL(This._internals._savedErrorHandler; ek errors from components)
+ This._internals._savedErrorHandler:=""
diff --git a/Project/Sources/Classes/_GoogleBaseList.4dm b/Project/Sources/Classes/_GoogleBaseList.4dm
index b19445b..5d17678 100644
--- a/Project/Sources/Classes/_GoogleBaseList.4dm
+++ b/Project/Sources/Classes/_GoogleBaseList.4dm
@@ -6,20 +6,22 @@ property statusText : Text
property success : Boolean
property errors : Collection
-Class constructor($inProvider : cs:C1710.OAuth2Provider; $inURL : Text; $inName : Text; $inHeaders : Object)
+Class constructor($inProvider : cs.OAuth2Provider; $inURL : Text; $inResultListName : Text; $inHeaders : Object; $inRequestSyncToken : Boolean)
- Super:C1705($inProvider)
+ Super($inProvider)
- This:C1470._internals._URL:=$inURL
- This:C1470._internals._headers:=$inHeaders
- This:C1470._internals._attribute:=$inName
- This:C1470._internals._nextPageToken:=""
- This:C1470._internals._history:=[]
-
- This:C1470.page:=1
- This:C1470.isLastPage:=False:C215
+ This._internals._URL:=$inURL
+ This._internals._headers:=$inHeaders
+ This._internals._attribute:=$inResultListName
+ This._internals._nextPageToken:=""
+ This._internals._requestSyncToken:=$inRequestSyncToken
+ This._internals._history:=[]
+ This._internals._throwErrors:=False
+
+ This.page:=1
+ This.isLastPage:=False
- This:C1470._getList()
+ This._getList()
// Mark: - [Private]
@@ -28,49 +30,50 @@ Class constructor($inProvider : cs:C1710.OAuth2Provider; $inURL : Text; $inName
Function _getList($inPageToken : Text) : Boolean
- var $URL : Text:=This:C1470._internals._URL
+ var $URL : Text:=This._internals._URL
- If (Length:C16(String:C10($inPageToken))>0)
+ If (Length(String($inPageToken))>0)
- var $sep : Text:=((Position:C15("?"; $URL)=0) ? "?" : "&")
- $URL+=$sep+"pageToken="+$inPageToken
+ var $sep : Text:=((Position("?"; $URL)=0) ? "?" : "&")
+ var $tokenName : Text:=This._internals._requestSyncToken ? "syncToken" : "pageToken"
+ $URL+=$sep+$tokenName+"="+$inPageToken
End if
- var $response : Object:=Super:C1706._sendRequestAndWaitResponse("GET"; $URL; This:C1470._internals._headers)
-
- This:C1470.isLastPage:=False:C215
- This:C1470.statusText:=Super:C1706._getStatusLine()
- This:C1470.success:=False:C215
- This:C1470._internals._nextPageToken:=""
+ var $response : Object:=Super._sendRequestAndWaitResponse("GET"; $URL; This._internals._headers)
- If ($response#Null:C1517)
+ This.isLastPage:=False
+ This.statusText:=Super._getStatusLine()
+ This.success:=False
+ This._internals._nextPageToken:=""
+ This._internals._list:=[]
+
+ If ($response#Null)
- If (OB Is defined:C1231($response; This:C1470._internals._attribute))
-
- This:C1470._internals._list:=OB Get:C1224($response; This:C1470._internals._attribute; Is collection:K8:32)
- Else
-
- This:C1470._internals._list:=[]
+ If (OB Is defined($response; This._internals._attribute))
+ This._internals._list:=OB Get($response; This._internals._attribute; Is collection)
End if
- This:C1470.success:=True:C214
- This:C1470._internals._history.push($inPageToken)
- This:C1470._internals._nextPageToken:=String:C10($response.nextPageToken)
- This:C1470.isLastPage:=(Length:C16(This:C1470._internals._nextPageToken)=0)
+ This.success:=True
+ This._internals._history.push($inPageToken)
+ If (This._internals._requestSyncToken)
+ This._internals._nextPageToken:=String($response.nextSyncToken)
+ Else
+ This._internals._nextPageToken:=String($response.nextPageToken)
+ End if
+ This.isLastPage:=(Length(This._internals._nextPageToken)=0)
- return True:C214
+ return True
Else
- var $errorStack : Collection:=Super:C1706._getErrorStack()
+ var $errorStack : Collection:=Super._getErrorStack()
If ($errorStack.length>0)
-
- This:C1470.errors:=$errorStack
- This:C1470.statusText:=$errorStack.first().message
+ This.errors:=$errorStack
+ This.statusText:=$errorStack.first().message
End if
- return False:C215
+ return False
End if
@@ -80,23 +83,23 @@ Function _getList($inPageToken : Text) : Boolean
Function next() : Boolean
- var $pageToken : Text:=String:C10(This:C1470._internals._nextPageToken)
+ var $pageToken : Text:=String(This._internals._nextPageToken)
- If (Length:C16($pageToken)>0)
+ If (Length($pageToken)>0)
- If (This:C1470._getList($pageToken))
+ If (This._getList($pageToken))
- This:C1470.page+=1
- return True:C214
+ This.page+=1
+ return True
End if
Else
- This:C1470.statusText:=Localized string:C991("List_No_Next_Page")
- This:C1470.isLastPage:=True:C214
+ This.statusText:=cs.Tools.me.localizedString("List_No_Next_Page")
+ This.isLastPage:=True
End if
- return False:C215
+ return False
// ----------------------------------------------------
@@ -104,25 +107,24 @@ Function next() : Boolean
Function previous() : Boolean
- If ((Num:C11(This:C1470._internals._history.length)>0) && (This:C1470.page>1))
+ If ((Num(This._internals._history.length)>0) && (This.page>1))
- var $index : Integer:=This:C1470.page-1
- var $pageToken : Text:=String:C10(This:C1470._internals._history[$index-1])
+ var $index : Integer:=This.page-1
+ var $pageToken : Text:=String(This._internals._history[$index-1])
- If (This:C1470._getList($pageToken))
+ If (This._getList($pageToken))
- This:C1470.page-=1
- This:C1470._internals._history.resize(This:C1470.page)
- This:C1470.isLastPage:=(This:C1470.page<=1)
+ This.page-=1
+ This._internals._history.resize(This.page)
+ This.isLastPage:=(This.page<=1)
- return True:C214
+ return True
End if
Else
- This:C1470.statusText:=Localized string:C991("List_No_Previous_Page")
- This:C1470.isLastPage:=True:C214
+ This.statusText:=cs.Tools.me.localizedString("List_No_Previous_Page")
+ This.isLastPage:=True
End if
- return False:C215
-
\ No newline at end of file
+ return False
diff --git a/Project/Sources/Classes/_GraphBaseList.4dm b/Project/Sources/Classes/_GraphBaseList.4dm
index 1c9e292..21b9601 100644
--- a/Project/Sources/Classes/_GraphBaseList.4dm
+++ b/Project/Sources/Classes/_GraphBaseList.4dm
@@ -6,17 +6,17 @@ property statusText : Text
property success : Boolean
property errors : Collection
-Class constructor($inProvider : cs:C1710.OAuth2Provider; $inURL : Text; $inHeaders : Object)
+Class constructor($inProvider : cs.OAuth2Provider; $inURL : Text; $inHeaders : Object)
- Super:C1705($inProvider)
+ Super($inProvider)
- This:C1470._internals._headers:=$inHeaders
- This:C1470._internals._history:=[$inURL]
- This:C1470._internals._list:=Null:C1517
- This:C1470.page:=1
- This:C1470.isLastPage:=False:C215
+ This._internals._headers:=$inHeaders
+ This._internals._history:=[$inURL]
+ This._internals._list:=Null
+ This.page:=1
+ This.isLastPage:=False
- This:C1470._getList($inURL)
+ This._getList($inURL)
// Mark: - [Private]
@@ -25,57 +25,57 @@ Class constructor($inProvider : cs:C1710.OAuth2Provider; $inURL : Text; $inHeade
Function _getList($inURL : Text) : Boolean
- var $response : Object:=Super:C1706._sendRequestAndWaitResponse("GET"; $inURL; This:C1470._internals._headers)
+ var $response : Object:=Super._sendRequestAndWaitResponse("GET"; $inURL; This._internals._headers)
- This:C1470.isLastPage:=False:C215
- This:C1470.statusText:=Super:C1706._getStatusLine()
- This:C1470.success:=False:C215
- This:C1470._internals._nextLink:=""
- This:C1470._internals._list:=[]
+ This.isLastPage:=False
+ This.statusText:=Super._getStatusLine()
+ This.success:=False
+ This._internals._nextLink:=""
+ This._internals._list:=[]
- If ($response#Null:C1517)
+ If ($response#Null)
var $result : Collection:=$response["value"]
var $object : Object
For each ($object; $result)
- This:C1470._internals._list.push(Super:C1706._cleanGraphObject($object))
+ This._internals._list.push(Super._cleanGraphObject($object))
End for each
- This:C1470.success:=True:C214
- var $nextLink : Text:=cs:C1710.Tools.me.urlDecode(String:C10($response["@odata.nextLink"]))
- var $count : Integer:=Num:C11($response["@odata.count"])
- If ((Length:C16($nextLink)>0) && (This:C1470._internals._list.length=$count))
+ This.success:=True
+ var $nextLink : Text:=cs.Tools.me.urlDecode(String($response["@odata.nextLink"]))
+ var $count : Integer:=Num($response["@odata.count"])
+ If ((Length($nextLink)>0) && (This._internals._list.length=$count))
$nextLink:=""
End if
- This:C1470._internals._nextLink:=$nextLink
- This:C1470.isLastPage:=(Length:C16(This:C1470._internals._nextLink)=0)
- return True:C214
+ This._internals._nextLink:=$nextLink
+ This.isLastPage:=(Length(This._internals._nextLink)=0)
+ return True
Else
- var $errorStack : Collection:=Super:C1706._getErrorStack()
+ var $errorStack : Collection:=Super._getErrorStack()
If ($errorStack.length>0)
- This:C1470.errors:=$errorStack
- This:C1470.statusText:=$errorStack.first().message
+ This.errors:=$errorStack
+ This.statusText:=$errorStack.first().message
End if
- return False:C215
+ return False
End if
-
-
+
+
// Mark: - [Public]
// ----------------------------------------------------
Function next() : Boolean
- var $URL : Text:=String:C10(This:C1470._internals._nextLink)
- If (Length:C16($URL)>0)
- var $bIsOK : Boolean:=This:C1470._getList($URL)
+ var $URL : Text:=String(This._internals._nextLink)
+ If (Length($URL)>0)
+ var $bIsOK : Boolean:=This._getList($URL)
If ($bIsOK)
- This:C1470._internals._history.push($URL)
- This:C1470.page+=1
+ This._internals._history.push($URL)
+ This.page+=1
End if
return $bIsOK
Else
- This:C1470.statusText:=Localized string:C991("List_No_Next_Page")
- return False:C215
+ This.statusText:=cs.Tools.me.localizedString("List_No_Next_Page")
+ return False
End if
@@ -84,19 +84,18 @@ Function next() : Boolean
Function previous() : Boolean
- If ((Num:C11(This:C1470._internals._history.length)>0) && (This:C1470.page>1))
- var $index : Integer:=This:C1470.page-1
- var $URL : Text:=String:C10(This:C1470._internals._history[$index-1])
- If (Length:C16($URL)>0)
- var $bIsOK : Boolean:=This:C1470._getList($URL)
+ If ((Num(This._internals._history.length)>0) && (This.page>1))
+ var $index : Integer:=This.page-1
+ var $URL : Text:=String(This._internals._history[$index-1])
+ If (Length($URL)>0)
+ var $bIsOK : Boolean:=This._getList($URL)
If ($bIsOK)
- This:C1470.page-=1
- This:C1470._internals._history.resize(This:C1470.page)
+ This.page-=1
+ This._internals._history.resize(This.page)
End if
return $bIsOK
End if
Else
- This:C1470.statusText:=Localized string:C991("List_No_Previous_Page")
- return False:C215
+ This.statusText:=cs.Tools.me.localizedString("List_No_Previous_Page")
+ return False
End if
-
\ No newline at end of file
diff --git a/Project/Sources/Methods/_onWebConnection.4dm b/Project/Sources/Methods/_onWebConnection.4dm
index 4b42867..15dfde4 100644
--- a/Project/Sources/Methods/_onWebConnection.4dm
+++ b/Project/Sources/Methods/_onWebConnection.4dm
@@ -2,17 +2,17 @@
#DECLARE($URL : Text; $header : Text; $peerIP : Text; $localIP : Text; $username : Text; $password : Text)
var $redirectURI : Text
-var $customResponseFile; $customErrorFile : 4D:C1709.File
-var $state : Text:=cs:C1710.Tools.me.getURLParameterValue($1; "state")
-var $responseFile : 4D:C1709.File:=Folder:C1567(fk resources folder:K87:11).file("Response_Template.html")
+var $customResponseFile; $customErrorFile : 4D.File
+var $state : Text:=cs.Tools.me.getURLParameterValue($1; "state")
+var $responseFile : 4D.File:=Folder(fk resources folder).file("Response_Template.html")
-If (OB Is defined:C1231(Storage:C1525.requests; $state))
- $redirectURI:=String:C10(Storage:C1525.requests[$state].redirectURI)
- If (Length:C16($redirectURI)>0)
- $redirectURI:=cs:C1710.Tools.me.getPathFromURL($redirectURI)+"@"
+If (OB Is defined(Storage.requests; $state))
+ $redirectURI:=String(Storage.requests[$state].redirectURI)
+ If (Length($redirectURI)>0)
+ $redirectURI:=cs.Tools.me.getPathFromURL($redirectURI)+"@"
End if
- $customResponseFile:=(Value type:C1509(Storage:C1525.requests[$state].authenticationPage)#Is undefined:K8:13) ? Storage:C1525.requests[$state].authenticationPage : Null:C1517
- $customErrorFile:=(Value type:C1509(Storage:C1525.requests[$state].authenticationErrorPage)#Is undefined:K8:13) ? Storage:C1525.requests[$state].authenticationErrorPage : Null:C1517
+ $customResponseFile:=(Value type(Storage.requests[$state].authenticationPage)#Is undefined) ? Storage.requests[$state].authenticationPage : Null
+ $customErrorFile:=(Value type(Storage.requests[$state].authenticationErrorPage)#Is undefined) ? Storage.requests[$state].authenticationErrorPage : Null
End if
If ($URL=$redirectURI)
@@ -20,58 +20,58 @@ If ($URL=$redirectURI)
var $result : Object
var WSTITLE; WSMESSAGE; WSDETAILS : Text
- ARRAY TEXT:C222($names; 0)
- ARRAY TEXT:C222($values; 0)
- WEB GET VARIABLES:C683($names; $values)
+ ARRAY TEXT($names; 0)
+ ARRAY TEXT($values; 0)
+ WEB GET VARIABLES($names; $values)
- If (Size of array:C274($names)>0)
+ If (Size of array($names)>0)
var $i : Integer
- $result:=New shared object:C1526
+ $result:=New shared object
Use ($result)
- For ($i; 1; Size of array:C274($names))
+ For ($i; 1; Size of array($names))
$result[$names{$i}]:=$values{$i}
End for
End use
End if
- If (OB Is defined:C1231(Storage:C1525.requests; $state))
- Use (Storage:C1525.requests[$state])
- Storage:C1525.requests[$state].token:=$result
+ If (OB Is defined(Storage.requests; $state))
+ Use (Storage.requests[$state])
+ Storage.requests[$state].token:=$result
End use
End if
- If (($result=Null:C1517) | (OB Is defined:C1231($result; "error")))
+ If (($result=Null) | (OB Is defined($result; "error")))
- WSTITLE:=Localized string:C991("OAuth2_Response_Title")
- WSMESSAGE:=Localized string:C991("OAuth2_Error_Message")
+ WSTITLE:=cs.Tools.me.localizedString("OAuth2_Response_Title")
+ WSMESSAGE:=cs.Tools.me.localizedString("OAuth2_Error_Message")
- If (OB Is defined:C1231($result; "error"))
+ If (OB Is defined($result; "error"))
WSMESSAGE:=WSMESSAGE+"
"+$result.error
End if
- If (OB Is defined:C1231($result; "error_subtype"))
+ If (OB Is defined($result; "error_subtype"))
WSMESSAGE:=WSMESSAGE+"
"+$result.error_subtype
End if
- If (OB Is defined:C1231($result; "error_description"))
+ If (OB Is defined($result; "error_description"))
WSMESSAGE:=WSMESSAGE+"
"+$result.error_description
End if
- If (OB Is defined:C1231($result; "error_uri"))
+ If (OB Is defined($result; "error_uri"))
WSMESSAGE:=WSMESSAGE+"
"+$result.error_uri
End if
- WSDETAILS:=Localized string:C991("OAuth2_Response_Details")
+ WSDETAILS:=cs.Tools.me.localizedString("OAuth2_Response_Details")
- $responseFile:=($customErrorFile#Null:C1517) ? $customErrorFile : $responseFile
+ $responseFile:=($customErrorFile#Null) ? $customErrorFile : $responseFile
Else
- WSTITLE:=Localized string:C991("OAuth2_Response_Title")
- WSMESSAGE:=Localized string:C991("OAuth2_Response_Message")
- WSDETAILS:=Localized string:C991("OAuth2_Response_Details")
+ WSTITLE:=cs.Tools.me.localizedString("OAuth2_Response_Title")
+ WSMESSAGE:=cs.Tools.me.localizedString("OAuth2_Response_Message")
+ WSDETAILS:=cs.Tools.me.localizedString("OAuth2_Response_Details")
- $responseFile:=($customResponseFile#Null:C1517) ? $customResponseFile : $responseFile
+ $responseFile:=($customResponseFile#Null) ? $customResponseFile : $responseFile
End if
- WEB SEND FILE:C619($responseFile.platformPath)
+ WEB SEND FILE($responseFile.platformPath)
Else