mirror of
https://github.com/flynx/ImageGrid.git
synced 2025-10-28 18:00:09 +00:00
cleanup, fixes and tweaks...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
5c78c95297
commit
2827e9e679
@ -955,6 +955,10 @@ function(list, options){
|
||||
: txt
|
||||
// account for '$' as key binding marker...
|
||||
var ntxt = txt.replace(/\$/g, '')
|
||||
// unique-test text...
|
||||
var utxt = options.unique instanceof Function ?
|
||||
options.unique(txt)+''
|
||||
: null
|
||||
|
||||
// invalid format...
|
||||
if(options.check && !options.check(txt)){
|
||||
@ -982,13 +986,13 @@ function(list, options){
|
||||
}
|
||||
|
||||
// check if item pre-existed...
|
||||
var preexisted = options.unique instanceof Function ?
|
||||
//lst.indexOf(options.unique(txt)) >= 0
|
||||
(lst.indexOf(options.unique(txt)) >= 0
|
||||
// account for '$' as key binding marker... (XXX ???)
|
||||
|| normalized.indexOf(options.unique(txt).replace(/\$/g, '')))
|
||||
: (lst.indexOf(txt) >= 0
|
||||
|| normalized.indexOf(ntxt) >= 0)
|
||||
var preexisted = utxt ?
|
||||
//lst.indexOf(options.unique(txt)) >= 0
|
||||
(lst.indexOf(utxt) >= 0
|
||||
// account for '$' as key binding marker... (XXX ???)
|
||||
|| normalized.indexOf(utxt.replace(/\$/g, '')) >= 0)
|
||||
: (lst.indexOf(txt) >= 0
|
||||
|| normalized.indexOf(ntxt) >= 0)
|
||||
|
||||
// add new value and sort list...
|
||||
lst.push(txt)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user