keith_hodges at yahoo.co.uk
Tue Apr 28 00:55:03 MEST 2009
Is the report column sorter supposed to be able to handle nil values?
This code (below) looks like it is trying to be tolerant But what if
two = nil.
thanks in advance
sort: aFirstObject and: aSecondObject
| one two |
one := self valueFor: aFirstObject.
two := self valueFor: aSecondObject.
(one respondsTo: #<=) ifFalse: [
one := self formatter value: one.
two := self formatter value: two ].
^ one <= two
More information about the smallwiki