Project

General

Profile

Actions

Bug #3793

closed

Text field update logs fail when all numbers

Added by nant almost 12 years ago. Updated almost 12 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
Start date:
27 November 2012
Due date:
% Done:

100%

Estimated time:

Description

If a text field has only digits in it is is not logged properly.

Example

000 evaluates to an empty field.

Actions #2

Updated by nant almost 12 years ago

Looks like this is due to the following PHP comparison issue:

http://php.net/manual/en/language.operators.comparison.php

If you compare a number with a string or the comparison involves numerical strings, then each string is converted to a number and the comparison performed numerically. These rules also apply to the switch statement. The type conversion does not take place when the comparison is === or !== as this involves comparing the type as well as the value.

So solutions seems to be:

cb.pulog.php line 605

change

if ($oA->$sKey != $oB->$sKey) {

to

if ((string) $oA->$sKey !== (string) $oB->$sKey) {

Actions #3

Updated by nant almost 12 years ago

Yup - this seems to fix the issue and not cause other issues.

Actions #4

Updated by nant almost 12 years ago

  • Status changed from Assigned to Resolved

resolved with r1037

Actions #5

Updated by nant almost 12 years ago

  • Target version changed from 1.5 to 1.4.1
Actions #6

Updated by nant almost 12 years ago

  • % Done changed from 0 to 100
Actions #7

Updated by nant almost 12 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF