summaryrefslogtreecommitdiffstatshomepage
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/SemanticScuttle/functions.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/SemanticScuttle/functions.php b/src/SemanticScuttle/functions.php
index 802a7f1..9bd5553 100644
--- a/src/SemanticScuttle/functions.php
+++ b/src/SemanticScuttle/functions.php
@@ -167,7 +167,8 @@ function createVoteURL($for, $bId)
function shortenString($string, $maxSize=75) {
$output = '';
if(strlen($string) > $maxSize) {
- $output = substr($string, 0, $maxSize/2).'...'.substr($string, -$maxSize/2);
+ //2023-12-20 add ROUND() function to avoid 'Deprecated' warning
+ $output = substr($string, 0, $maxSize/2).'...'.substr($string, -round($maxSize/2));
} else {
$output = $string;
}