1
0
Fork 0
mirror of https://github.com/FrankerFaceZ/FrankerFaceZ.git synced 2025-07-26 04:28:31 +00:00

3.5.266. Yeah. This is me remembering to commit again, but only because I told someone to make a pull request.

This commit is contained in:
SirStendec 2016-08-09 20:45:28 -04:00
parent 86546ba7d8
commit 8310f89aa0
25 changed files with 717 additions and 592 deletions

View file

@ -9,11 +9,30 @@ var FFZ = window.FrankerFaceZ,
};
// ---------------------
// Badware Check
// ---------------------
FFZ.prototype.check_badware = function() {
if ( this.embed_in_dash || ! window.jQuery || ! window.jQuery.noty )
return;
// Check for the stolen version of BTTV4FFZ.
if ( FFZ.settings_info.bttv_global_emotes && FFZ.settings_info.bttv_global_emotes.category === "BetterTTV" ) {
var shown = localStorage.ffz_warning_bttv4ffz_clone;
if ( shown !== "true" ) {
localStorage.ffz_warning_bttv4ffz_clone = "true";
this.show_message("You appear to be using an unofficial version of BTTV4FFZ that was copied without the developer's permission. Please use the official version available at <a href=\"https://lordmau5.com/bttv4ffz/\">https://lordmau5.com/bttv4ffz/</a>");
}
}
}
// ---------------------
// API Constructor
// ---------------------
var API = FFZ.API = function(instance, name, icon, version) {
var API = FFZ.API = function(instance, name, icon, version, name_key) {
this.ffz = instance || FFZ.get();
// Check for a known API!
@ -56,7 +75,7 @@ var API = FFZ.API = function(instance, name, icon, version) {
this.on_room_callbacks = [];
this.name = name || ("Extension#" + this.id);
this.name_key = this.name.replace(/[^A-Z0-9_\-]/g, '').toLowerCase();
this.name_key = name_key || this.name.replace(/[^A-Z0-9_\-]/g, '').toLowerCase();
this.icon = icon || null;
this.version = version || null;