From c25d28dcac6df73879d4a190a79b41f541cccc9b Mon Sep 17 00:00:00 2001 From: Ivan Iraci Date: Thu, 5 Nov 2020 18:39:00 +0100 Subject: [PATCH 1/2] Fixes count with Object(stdClass). On Php 7.3 you get this exception: ErrorException(code: 0): count(): Parameter must be an array or an object that implements Countable at rusticisoftware/tincan/src/Map.php:49 This commit fixes it. --- src/Map.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Map.php b/src/Map.php index 09eff6e..3d9da97 100644 --- a/src/Map.php +++ b/src/Map.php @@ -46,7 +46,7 @@ private function _unset($code) { } public function isEmpty() { - return count($this->_map) === 0; + return count((array)($this->_map)) === 0; } public function __call($func, $args) { From be10374caa1a3014bbe8f528169bce0f2700cd6f Mon Sep 17 00:00:00 2001 From: Ivan Iraci Date: Thu, 5 Nov 2020 19:40:04 +0100 Subject: [PATCH 2/2] Edited composer.json in order to publish package. --- composer.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/composer.json b/composer.json index be50a03..39869f5 100644 --- a/composer.json +++ b/composer.json @@ -1,8 +1,8 @@ { - "name": "rusticisoftware/tincan", + "name": "taylora/tincan", "type": "library", "description": "Experience API (Tin Can API) Library", - "homepage": "http://rusticisoftware.github.io/TinCanPHP/", + "homepage": "https://github.com/TayloraLMS/TinCanPHP", "keywords": [ "tin can", "tincan",