Improved sort, only use lower if attribute is a string.
This commit is contained in:
parent
99f64668e7
commit
0207cfe0e8
1 changed files with 5 additions and 2 deletions
|
@ -553,8 +553,11 @@ class App.Model extends Spine.Model
|
||||||
return '' if item[ attribute ] is undefined
|
return '' if item[ attribute ] is undefined
|
||||||
return '' if item[ attribute ] is null
|
return '' if item[ attribute ] is null
|
||||||
|
|
||||||
# return value
|
# return value if string
|
||||||
item[ attribute ].toLowerCase()
|
if item[ attribute ].toLowerCase
|
||||||
|
return item[ attribute ].toLowerCase()
|
||||||
|
|
||||||
|
item[ attribute ]
|
||||||
)
|
)
|
||||||
|
|
||||||
@_order: ( collection, attribute ) ->
|
@_order: ( collection, attribute ) ->
|
||||||
|
|
Loading…
Reference in a new issue