From c872fb34bbea186da40f741f0fbcdf34fbeeae77 Mon Sep 17 00:00:00 2001 From: Imran Hussain <imranh@sucs.org> Date: Mon, 13 Apr 2015 19:39:19 +0000 Subject: [PATCH] Meger changes from beta into live site --- components/libraryadmin.php | 2 +- lib/Validate/ISPN.php | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/components/libraryadmin.php b/components/libraryadmin.php index 0c15a06..0517381 100644 --- a/components/libraryadmin.php +++ b/components/libraryadmin.php @@ -16,7 +16,7 @@ function fetch_isbndb_data($isbn) { function valid_isbn($isbn) { - return Validate_ISPN::isbn($isbn); + return (new Validate_ISPN)->isbn($isbn); } if ($session->groups[$permission]) { diff --git a/lib/Validate/ISPN.php b/lib/Validate/ISPN.php index 78c9c3d..bb61785 100644 --- a/lib/Validate/ISPN.php +++ b/lib/Validate/ISPN.php @@ -141,7 +141,7 @@ class Validate_ISPN // Requires base class Validate require_once 'Validate.php'; - return Validate::_checkControlNumber($isbn, $weights_isbn, 11, 11); + return (new Validate)->_checkControlNumber($isbn, $weights_isbn, 11, 11); } @@ -172,7 +172,7 @@ class Validate_ISPN // Requires base class Validate require_once 'Validate.php'; - return Validate::_checkControlNumber($issn, $weights_issn, 11, 11); + return (new Validate)->_checkControlNumber($issn, $weights_issn, 11, 11); } /** @@ -212,7 +212,7 @@ class Validate_ISPN // Requires base class Validate require_once 'Validate.php'; - return Validate::_checkControlNumber($ismn, $weights_ismn, 10, 10); + return (new Validate)->_checkControlNumber($ismn, $weights_ismn, 10, 10); } /** @@ -349,7 +349,7 @@ class Validate_ISPN * @param array $weights holds the weight that will be used in calculations for the validation * @return bool true if number is valid, otherwise false * @access public - * @see Validate::_checkControlNumber() + * @see (new Validate)->_checkControlNumber() */ function process($data, $length, &$weights, $modulo = 10, $subtract = 0) { @@ -365,7 +365,7 @@ class Validate_ISPN // Requires base class Validate require_once 'Validate.php'; - return Validate::_checkControlNumber($data, $weights, $modulo, $subtract); + return (new Validate)->_checkControlNumber($data, $weights, $modulo, $subtract); } } ?> -- GitLab