1
0
Fork 0
mirror of https://github.com/FrankerFaceZ/FrankerFaceZ.git synced 2025-07-27 13:08:30 +00:00

Removed Firefox update warning. Made styles attempt to re-downlaod with new URLs upon error due to CDN issues. Made viewer list sorting optional. Added safety checks to API for non-global sets.

This commit is contained in:
SirStendec 2015-10-27 21:22:54 -04:00
parent acc0010247
commit a7f6e0b63f
6 changed files with 30 additions and 13 deletions

View file

@ -259,6 +259,11 @@ API.prototype.register_global_set = function(id, emote_set) {
throw new Error("Invalid set ID");
// Make sure the set is still available with FFZ.
if ( ! this.ffz.emote_sets[exact_id] )
this.ffz.emote_sets[exact_id] = emote_set;
// It's a valid set if we get here, so make it global.
if ( this.global_sets.indexOf(exact_id) === -1 )
this.global_sets.push(exact_id);
@ -323,6 +328,10 @@ API.prototype.register_room_set = function(room_id, id, emote_set) {
if ( ! emote_set )
throw new Error("Invalid set ID");
// Make sure the set is still available with FFZ.
if ( ! this.ffz.emote_sets[exact_id] )
this.ffz.emote_sets[exact_id] = emote_set;
// Register it on the room.
room.ext_sets.push(exact_id);
emote_set.users.push(room_id);