@@ -727,12 +727,6 @@ Func _WD_Window($sSession, $sCommand, $sOption = Default)
727
727
$oJson = Json_Decode($sResponse )
728
728
$sResult = Json_Get($oJson , " [value]" )
729
729
EndSwitch
730
-
731
- ElseIf $_WD_HTTPRESULT = $HTTP_STATUS_NOT_FOUND Then
732
- $oJson = Json_Decode($sResponse )
733
- $sErr = Json_Get($oJson , " [value][error]" )
734
- $iErr = ($sErr == $WD_Element_Stale ) ? $_WD_ERROR_NoMatch : $_WD_ERROR_Exception
735
-
736
730
Else
737
731
$iErr = $_WD_ERROR_Exception
738
732
EndIf
@@ -814,11 +808,6 @@ Func _WD_FindElement($sSession, $sStrategy, $sSelector, $sStartElement = Default
814
808
$sResult = Json_Get($oJson , " [value][" & $_WD_ELEMENT_ID & " ]" )
815
809
EndIf
816
810
817
- ElseIf $_WD_HTTPRESULT = $HTTP_STATUS_NOT_FOUND Then
818
- $oJson = Json_Decode($sResponse )
819
- $sErr = Json_Get($oJson , " [value][error]" )
820
- $iErr = ($sErr == $WD_Element_NotFound ) ? $_WD_ERROR_NoMatch : $_WD_ERROR_Exception
821
-
822
811
Else
823
812
$iErr = $_WD_ERROR_Exception
824
813
EndIf
@@ -908,26 +897,6 @@ Func _WD_ElementAction($sSession, $sElement, $sCommand, $sOption = Default)
908
897
$sResult = Json_Get($oJson , " [value]" )
909
898
EndSwitch
910
899
911
- Case $HTTP_STATUS_NOT_FOUND
912
- $oJson = Json_Decode($sResponse )
913
- $sErr = Json_Get($oJson , " [value][error]" )
914
- $iErr = ($sErr == $WD_Element_Stale ) ? $_WD_ERROR_NoMatch : $_WD_ERROR_Exception
915
-
916
- Case $HTTP_STATUS_BAD_REQUEST
917
- $oJson = Json_Decode($sResponse )
918
- $sErr = Json_Get($oJson , " [value][error]" )
919
-
920
- Switch $sErr
921
- Case $WD_Element_Invalid
922
- $iErr = $_WD_ERROR_InvalidArgue
923
-
924
- Case $WD_Element_Intercept , $WD_Element_NotInteract
925
- $iErr = $_WD_ERROR_ElementIssue
926
-
927
- Case Else
928
- $iErr = $_WD_ERROR_Exception
929
- EndSwitch
930
-
931
900
Case Else
932
901
$iErr = $_WD_ERROR_Exception
933
902
EndSwitch
@@ -992,9 +961,6 @@ Func _WD_ExecuteScript($sSession, $sScript, $sArguments = Default, $lAsync = Def
992
961
EndIf
993
962
994
963
Return SetError ($_WD_ERROR_Success , $_WD_HTTPRESULT , $sResponse )
995
-
996
-
997
- ; ~ Return SetError(($_WD_HTTPRESULT <> $HTTP_STATUS_OK) ? $_WD_ERROR_GeneralError : $_WD_ERROR_Success, $_WD_HTTPRESULT, $sResponse)
998
964
EndFunc ; ==>_WD_ExecuteScript
999
965
1000
966
@@ -1737,8 +1703,6 @@ Func __WD_TranslateQuotes($sData)
1737
1703
Return SetError ($_WD_ERROR_Success , 0 , $sResult )
1738
1704
EndFunc
1739
1705
1740
-
1741
-
1742
1706
; #INTERNAL_USE_ONLY# ===========================================================================================================
1743
1707
; Name ..........: __WD_DetectError
1744
1708
; Description ...: Evaluate results from webdriver to identify errors
0 commit comments