Skip to content

Commit 1edc9d5

Browse files
committed
v2.5.8 - Fix for function isFloatBiggerThanZero
1 parent 1e633d9 commit 1edc9d5

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

pdfScale.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# Writen for Bash.
1010
#
1111
# Gustavo Arnosti Neves - 2016 / 07 / 10
12-
# Latest Version - 2020 / 04 / 04
12+
# Latest Version - 2023 / 01 / 26
1313
#
1414
# This app: https://github.com/tavinus/pdfScale
1515
#
@@ -20,7 +20,7 @@
2020
#
2121
################################################################
2222

23-
VERSION="2.5.7"
23+
VERSION="2.5.8"
2424

2525

2626
###################### EXTERNAL PROGRAMS #######################
@@ -2042,7 +2042,7 @@ isFloat() {
20422042

20432043
# Returns $TRUE if $1 is a floating point number bigger than zero, $FALSE otherwise
20442044
isFloatBiggerThanZero() {
2045-
isFloat "$1" && [[ (( $1 > 0 )) ]] && return $TRUE
2045+
isFloat "$1" && [[ "$1" =~ ^0*[1-9] || "$1" =~ ^0*[.]0*[1-9] ]] && return $TRUE
20462046
return $FALSE
20472047
}
20482048

0 commit comments

Comments
 (0)