1
0
Fork 0
mirror of https://github.com/FrankerFaceZ/FrankerFaceZ.git synced 2025-09-17 10:16:57 +00:00

Replace all the process_value functions with a helper from utilities. Hide creative tags on the channel page.

This commit is contained in:
SirStendec 2016-10-01 14:11:49 -04:00
parent 7d35b5c8c3
commit 91051d2a11
15 changed files with 197 additions and 339 deletions

View file

@ -1236,15 +1236,7 @@ FFZ.settings_info.stream_uptime = {
},
value: 1,
process_value: function(val) {
if ( val === false )
return 0;
if ( val === true )
return 2;
if ( typeof val === "string" )
return parseInt(val || "0") || 0;
return val;
},
process_value: utils.process_int(1, 0, 2),
no_mobile: true,
category: "Channel Metadata",
@ -1370,14 +1362,7 @@ FFZ.settings_info.channel_title_top = {
},
value: 0,
process_value: function(val) {
if ( typeof val === "string" ) {
val = parseInt(val);
if ( isNaN(val) || ! isFinite(val) )
val = 0;
}
return val;
},
process_value: utils.process_int(0),
no_bttv: true,
no_mobile: true,