Use get_called_class() if available.

This commit is contained in:
Andreas Fischer 2014-06-27 00:35:19 +02:00
parent 73f961cb7d
commit 0f672dde52

View File

@ -138,7 +138,8 @@ class Net_SFTP_Stream
if (in_array($protocol, stream_get_wrappers(), true)) {
return false;
}
return stream_wrapper_register($protocol, __CLASS__);
$class = function_exists('get_called_class') ? get_called_class() : __CLASS__;
return stream_wrapper_register($protocol, $class);
}
/**