Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
CentralNic
php-epp
Commits
e15db31f
Commit
e15db31f
authored
Feb 11, 2013
by
Gavin Brown
Browse files
don't use PEAR::isError, use instanceof instead.
parent
1fccbd6d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Net/EPP/Client.php
View file @
e15db31f
...
...
@@ -109,10 +109,14 @@
* @return PEAR_Error|string the frame returned by the server, or an error object
*/
function
request
(
$xml
)
{
if
(
PEAR
::
isError
(
$res
=
$this
->
sendFrame
(
$xml
)))
{
$res
=
$this
->
sendFrame
(
$xml
);
if
(
$res
instanceof
PEAR_Error
)
{
return
$res
;
}
else
{
return
$this
->
getFrame
();
}
return
$this
->
getFrame
();
}
/**
...
...
Net/EPP/Protocol.php
View file @
e15db31f
...
...
@@ -70,9 +70,8 @@ class Net_EPP_Protocol {
*/
static
function
getFrame
(
$socket
)
{
// Read header
if
(
PEAR
::
isError
(
$hdr
=
Net_EPP_Protocol
::
_fread_nb
(
$socket
,
4
)))
{
return
$hdr
;
}
$hdr
=
Net_EPP_Protocol
::
_fread_nb
(
$socket
,
4
);
if
(
$hdr
instanceof
PEAR_Error
)
return
$hdr
;
// Unpack first 4 bytes which is our length
$unpacked
=
unpack
(
'N'
,
$hdr
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment