Use constants in place of class constants

Signed-off-by: RD WebDesign <github@rdwebdesign.com.br>
This commit is contained in:
RD WebDesign
2022-09-08 23:47:09 -03:00
parent eb83420caf
commit d12ef014e5
4 changed files with 20 additions and 24 deletions

View File

@@ -7,6 +7,12 @@
* Please see LICENSE file for your rights under this license
*/
// List Type Constants
const LISTTYPE_WHITELIST = 0;
const LISTTYPE_BLACKLIST = 1;
const LISTTYPE_REGEX_WHITELIST = 2;
const LISTTYPE_REGEX_BLACKLIST = 3;
function getGravityDBFilename()
{
// Get possible non-standard location of FTL's database
@@ -278,13 +284,3 @@ function remove_from_table($db, $table, $domains, $returnnum = false, $type = -1
return 'Success, removed '.$num.' domain'.$plural;
}
if (!class_exists('ListType')) {
class ListType
{
public const whitelist = 0;
public const blacklist = 1;
public const regex_whitelist = 2;
public const regex_blacklist = 3;
}
}