MDL-45660 question statistics: make comparison more robust.
[moodle.git] / question / classes / statistics / responses / analysis_for_class.php
index 872f020..efb7d7b 100644 (file)
@@ -145,7 +145,7 @@ class analysis_for_class {
             return true;
         } else if (count($actualresponses) === 1) {
             $singleactualresponse = reset($actualresponses);
-            return (string)$singleactualresponse != $this->modelresponse;
+            return (string)$singleactualresponse !== (string)$this->modelresponse;
         }
         return false;
     }