From 8e197cd42a953fd69d84b3fb59b8219b1584a0a3 Mon Sep 17 00:00:00 2001 From: buckaroo-labs Date: Wed, 20 Dec 2023 17:46:35 -0800 Subject: PHP 8 updates add IF condition to avoid 'Deprecated' warning--- src/SemanticScuttle/Service/Tag.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/SemanticScuttle/Service/Tag.php b/src/SemanticScuttle/Service/Tag.php index bd6bf70..17acae7 100644 --- a/src/SemanticScuttle/Service/Tag.php +++ b/src/SemanticScuttle/Service/Tag.php @@ -137,7 +137,8 @@ class SemanticScuttle_Service_Tag extends SemanticScuttle_DbService /* normalize the input tags which could be a string or an array*/ function normalize($tags) { //clean tags from strange characters - $tags = str_replace(array('"', '\'', '/'), "_", $tags); + //2023-12-20 add IF condition to avoid 'Deprecated' warning + if (!is_null($tags)) $tags = str_replace(array('"', '\'', '/'), "_", $tags); //normalize if(!is_array($tags)) { -- cgit v1.2.3-54-g00ecf