this cleanup uses standard backbone architecture to avoid sorting
prior to all collections being loaded. i've included a note for
future developers about the issue, and added some defensive coding
for all other collections being loaded, to prevent similar issues
in the future.
for testing, i added a console log to the user comparator, and this
log output shows it's not called until after all collections are loaded:
info: redis ready
info: redis-sync initialized
info: loading user/*
info: loading event/?????
info: loading event/*/hoa/*
warn: No redis data for event/*/hoa/*
info: loading event/*/sessions/*
info: loading session/permalink/*
warn: No redis data for session/permalink/*
info: Done loading models.
HIT COMPARATOR
HIT COMPARATOR
HIT COMPARATOR
HIT COMPARATOR
HIT COMPARATOR
HIT COMPARATOR
this cleanup uses standard backbone architecture to avoid sorting prior to all collections being loaded. i've included a note for future developers about the issue, and added some defensive coding for all other collections being loaded, to prevent similar issues in the future.
for testing, i added a console log to the user comparator, and this log output shows it's not called until after all collections are loaded: