summaryrefslogtreecommitdiffstats
path: root/3dparty
diff options
context:
space:
mode:
authorThomas Zander <zander@kde.org>2011-06-08 23:12:06 +0200
committerThomas Zander <zander@kde.org>2011-06-13 13:48:25 +0200
commit80194daec7b612a356daac7c13ccc904a70ffbbf (patch)
tree15a47e3c441231b4a03b2f6509e8297b3f05b19d /3dparty
parent1ea43dd7f9928ac6e74f36822ccb4deeeb804db3 (diff)
downloadnextcloud-server-80194daec7b612a356daac7c13ccc904a70ffbbf.tar.gz
nextcloud-server-80194daec7b612a356daac7c13ccc904a70ffbbf.zip
Fix php4 legacy calls
Reviewed-by: Robin Appelman Reviewboard: http://git.reviewboard.kde.org/r/101549/
Diffstat (limited to '3dparty')
-rw-r--r--3dparty/MDB2.php10
-rw-r--r--3dparty/MDB2/Schema/Parser.php9
-rw-r--r--3dparty/MDB2/Schema/Validate.php5
-rw-r--r--3dparty/PEAR.php12
4 files changed, 12 insertions, 24 deletions
diff --git a/3dparty/MDB2.php b/3dparty/MDB2.php
index 30e564f1457..fbc7107914e 100644
--- a/3dparty/MDB2.php
+++ b/3dparty/MDB2.php
@@ -639,7 +639,7 @@ class MDB2
*/
static function isError($data, $code = null)
{
- if (is_a($data, 'MDB2_Error')) {
+ if ($data instanceof MDB2_Error) {
if (is_null($code)) {
return true;
} elseif (is_string($code)) {
@@ -666,7 +666,7 @@ class MDB2
*/
static function isConnection($value)
{
- return is_a($value, 'MDB2_Driver_Common');
+ return ($value instanceof MDB2_Driver_Common);
}
// }}}
@@ -683,7 +683,7 @@ class MDB2
*/
static function isResult($value)
{
- return is_a($value, 'MDB2_Result');
+ return $value instanceof MDB2_Result;
}
// }}}
@@ -700,7 +700,7 @@ class MDB2
*/
static function isResultCommon($value)
{
- return is_a($value, 'MDB2_Result_Common');
+ return ($value instanceof MDB2_Result_Common);
}
// }}}
@@ -717,7 +717,7 @@ class MDB2
*/
static function isStatement($value)
{
- return is_a($value, 'MDB2_Statement_Common');
+ return $value instanceof MDB2_Statement_Common;
}
// }}}
diff --git a/3dparty/MDB2/Schema/Parser.php b/3dparty/MDB2/Schema/Parser.php
index bd7a9657932..b740ef55fa8 100644
--- a/3dparty/MDB2/Schema/Parser.php
+++ b/3dparty/MDB2/Schema/Parser.php
@@ -127,13 +127,6 @@ class MDB2_Schema_Parser extends XML_Parser
$this->val =new MDB2_Schema_Validate($fail_on_invalid_names, $valid_types, $force_defaults);
}
- function MDB2_Schema_Parser($variables, $fail_on_invalid_names = true,
- $structure = false, $valid_types = array(),
- $force_defaults = true)
- {
- $this->__construct($variables, $fail_on_invalid_names, $structure, $valid_types, $force_defaults);
- }
-
function startHandler($xp, $element, $attribs)
{
if (strtolower($element) == 'variable') {
@@ -503,7 +496,7 @@ class MDB2_Schema_Parser extends XML_Parser
$this->element = implode('-', $this->elements);
}
- function &raiseError($msg = null, $xmlecode = 0, $xp = null, $ecode = MDB2_SCHEMA_ERROR_PARSE,$a=null,$b=null,$c=null)
+ function raiseError($msg = null, $xmlecode = 0, $xp = null, $ecode = MDB2_SCHEMA_ERROR_PARSE,$a=null,$b=null,$c=null)
{
if (is_null($this->error)) {
$error = '';
diff --git a/3dparty/MDB2/Schema/Validate.php b/3dparty/MDB2/Schema/Validate.php
index 21be024ce9f..217cf51b959 100644
--- a/3dparty/MDB2/Schema/Validate.php
+++ b/3dparty/MDB2/Schema/Validate.php
@@ -91,11 +91,6 @@ class MDB2_Schema_Validate
$this->force_defaults = $force_defaults;
}
- function MDB2_Schema_Validate($fail_on_invalid_names = true, $valid_types = array(), $force_defaults = true)
- {
- $this->__construct($fail_on_invalid_names, $valid_types, $force_defaults);
- }
-
// }}}
// {{{ raiseError()
diff --git a/3dparty/PEAR.php b/3dparty/PEAR.php
index 9760b9d265a..f832c0d4916 100644
--- a/3dparty/PEAR.php
+++ b/3dparty/PEAR.php
@@ -249,7 +249,7 @@ class PEAR
*/
static function isError($data, $code = null)
{
- if (is_a($data, 'PEAR_Error')) {
+ if ($data instanceof PEAR_Error) {
if (is_null($code)) {
return true;
} elseif (is_string($code)) {
@@ -305,7 +305,7 @@ class PEAR
function setErrorHandling($mode = null, $options = null)
{
- if (isset($this) && is_a($this, 'PEAR')) {
+ if (isset($this) && $this instanceof PEAR) {
$setmode = &$this->_default_error_mode;
$setoptions = &$this->_default_error_options;
} else {
@@ -557,7 +557,7 @@ class PEAR
$code = null,
$userinfo = null)
{
- if (isset($this) && is_a($this, 'PEAR')) {
+ if (isset($this) && $this instanceof PEAR) {
return $this->raiseError($message, $code, null, null, $userinfo);
} else {
return PEAR::raiseError($message, $code, null, null, $userinfo);
@@ -653,7 +653,7 @@ class PEAR
function pushErrorHandling($mode, $options = null)
{
$stack = &$GLOBALS['_PEAR_error_handler_stack'];
- if (isset($this) && is_a($this, 'PEAR')) {
+ if (isset($this) && $this instanceof PEAR) {
$def_mode = &$this->_default_error_mode;
$def_options = &$this->_default_error_options;
} else {
@@ -662,7 +662,7 @@ class PEAR
}
$stack[] = array($def_mode, $def_options);
- if (isset($this) && is_a($this, 'PEAR')) {
+ if (isset($this) && $this instanceof PEAR) {
$this->setErrorHandling($mode, $options);
} else {
PEAR::setErrorHandling($mode, $options);
@@ -687,7 +687,7 @@ class PEAR
array_pop($stack);
list($mode, $options) = $stack[sizeof($stack) - 1];
array_pop($stack);
- if (isset($this) && is_a($this, 'PEAR')) {
+ if (isset($this) && $this instanceof PEAR) {
$this->setErrorHandling($mode, $options);
} else {
PEAR::setErrorHandling($mode, $options);