Better check for integer when cleaning parameter

This commit is contained in:
moodler
2004-10-01 15:04:21 +00:00
parent edfa37ae27
commit 98cda81fcf
+1 -1
View File
@@ -81,7 +81,7 @@ function clean_param($param, $options) {
/// Given a parameter and a bitfield of options, this function
/// will clean it up and give it the required type, etc.
if ($param == (int)$param) { // It's just an integer
if ((string)$param == (string)(int)$param) { // It's just an integer
return $param;
}