diff --git a/CHANGELOG.md b/CHANGELOG.md
index 9bb28be9..488d38c9 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -21,7 +21,7 @@
**Merged pull requests:**
- Release v2.1.5-2023.05 🎉
-- Minor improvements [\#167](https://github.com/torrentpier/torrentpier-lts/pull/167), [\#168](https://github.com/torrentpier/torrentpier-lts/pull/168), [\#169](https://github.com/torrentpier/torrentpier-lts/pull/169), [\#170](https://github.com/torrentpier/torrentpier-lts/pull/170) ([belomaxorka](https://github.com/belomaxorka))
+- Minor improvements [\#169](https://github.com/torrentpier/torrentpier-lts/pull/169), [\#170](https://github.com/torrentpier/torrentpier-lts/pull/170) ([belomaxorka](https://github.com/belomaxorka))
## [v2.1.5-2023.04](https://github.com/torrentpier/torrentpier-lts/tree/v2.1.5-2023.04) (2023-05-04)
[Full Changelog](https://github.com/torrentpier/torrentpier-lts/compare/v2.1.5-2023.03...v2.1.5-2023.04)
diff --git a/admin/admin_ranks.php b/admin/admin_ranks.php
index b79b8e61..641ea54e 100644
--- a/admin/admin_ranks.php
+++ b/admin/admin_ranks.php
@@ -200,7 +200,7 @@ if ($mode != '')
}
else
{
- bb_die('Invalid mode: ' . htmlCHR($mode));
+ bb_die('Invalid mode');
}
}
else
diff --git a/admin/admin_user_search.php b/admin/admin_user_search.php
index b7138fdc..d997a052 100644
--- a/admin/admin_user_search.php
+++ b/admin/admin_user_search.php
@@ -245,7 +245,7 @@ else
break;
default:
- bb_die('Invalid mode: ' . htmlCHR($mode));
+ bb_die('Invalid mode');
}
$base_url = 'admin_user_search.php?dosearch=true';
diff --git a/bt/announce.php b/bt/announce.php
index 1008fbb9..6268d47d 100644
--- a/bt/announce.php
+++ b/bt/announce.php
@@ -76,31 +76,31 @@ $passkey = isset($$passkey_key) ? $$passkey_key : null;
// Required params (info_hash, peer_id, port, uploaded, downloaded, left, passkey)
if (!isset($info_hash) || strlen($info_hash) != 20)
{
- msg_die('Invalid info_hash: ' . htmlCHR($info_hash));
+ msg_die('Invalid info_hash');
}
if (!isset($peer_id) || strlen($peer_id) != 20)
{
- msg_die('Invalid peer_id: ' . htmlCHR($peer_id));
+ msg_die('Invalid peer_id');
}
if (!isset($port) || $port < 0 || $port > 0xFFFF)
{
- msg_die('Invalid port: ' . htmlCHR($port));
+ msg_die('Invalid port');
}
if (!isset($uploaded) || $uploaded < 0 || $uploaded > $max_up_down_val || $uploaded == 1844674407370)
{
- msg_die('Invalid uploaded value: ' . htmlCHR($uploaded));
+ msg_die('Invalid uploaded value');
}
if (!isset($downloaded) || $downloaded < 0 || $downloaded > $max_up_down_val || $downloaded == 1844674407370)
{
- msg_die('Invalid downloaded value: ' . htmlCHR($downloaded));
+ msg_die('Invalid downloaded value');
}
if (!isset($left) || $left < 0 || $left > $max_left_val)
{
- msg_die('Invalid left value: ' . htmlCHR($left));
+ msg_die('Invalid left value');
}
if (!verify_id($passkey, BT_AUTH_KEY_LENGTH))
{
- msg_die('Invalid passkey: ' . htmlCHR($passkey));
+ msg_die('Invalid passkey');
}
// IP
diff --git a/bt/scrape.php b/bt/scrape.php
index 72dc68ea..e09ebbb9 100644
--- a/bt/scrape.php
+++ b/bt/scrape.php
@@ -14,7 +14,7 @@ if (isset($_GET['?info_hash']) && !isset($_GET['info_hash']))
if (!isset($_GET['info_hash']) || strlen($_GET['info_hash']) != 20)
{
- msg_die('Invalid info_hash: ' . htmlCHR($_GET['info_hash']));
+ msg_die('Invalid info_hash');
}
$info_hash = $_GET['info_hash'];
diff --git a/info.php b/info.php
index 73e36542..500596c8 100644
--- a/info.php
+++ b/info.php
@@ -36,7 +36,7 @@ switch ($req_mode)
break;
default:
- bb_simple_die('Invalid request: ' . htmlCHR($req_mode));
+ bb_simple_die('Invalid request');
}
$require = file_exists($html_dir . $info['src']) ? $html_dir . $info['src'] : $html_dir . 'not_found.html';
diff --git a/library/ajax/avatar.php b/library/ajax/avatar.php
index 6c58ee8d..ef61deac 100644
--- a/library/ajax/avatar.php
+++ b/library/ajax/avatar.php
@@ -9,7 +9,7 @@ $user_id = (int) $this->request['user_id'];
if (!$user_id OR !$u_data = get_userdata($user_id))
{
- $this->ajax_die('Invalid user_id: ' . htmlCHR($user_id));
+ $this->ajax_die('Invalid user_id');
}
if (!IS_ADMIN && $user_id != $user->id)
@@ -25,7 +25,7 @@ switch ($mode)
$response = '';
break;
default:
- $this->ajax_die('Invalid mode: ' . htmlCHR($mode));
+ $this->ajax_die('Invalid mode');
}
DB()->query("UPDATE ". BB_USERS ." SET avatar_ext_id = $new_ext_id WHERE user_id = $user_id LIMIT 1");
diff --git a/library/ajax/change_user_opt.php b/library/ajax/change_user_opt.php
index 7e02037f..db9fc94e 100644
--- a/library/ajax/change_user_opt.php
+++ b/library/ajax/change_user_opt.php
@@ -9,12 +9,12 @@ $new_opt = Zend\Json\Json::decode($this->request['user_opt'], Zend\Json\Json::TY
if (!$user_id OR !$u_data = get_userdata($user_id))
{
- $this->ajax_die('invalid user_id: ' . htmlCHR($user_id));
+ $this->ajax_die('invalid user_id');
}
if (!is_array($new_opt))
{
- $this->ajax_die('invalid new_opt: ' . htmlCHR($new_opt));
+ $this->ajax_die('invalid new_opt');
}
foreach ($bf['user_opt'] as $opt_name => $opt_bit)
diff --git a/library/ajax/group_membership.php b/library/ajax/group_membership.php
index df0f0cdc..78b9c307 100644
--- a/library/ajax/group_membership.php
+++ b/library/ajax/group_membership.php
@@ -65,5 +65,5 @@ switch ($mode)
break;
default:
- $this->ajax_die('Invalid mode: ' . htmlCHR($mode));
+ $this->ajax_die("invalid mode: $mode");
}
\ No newline at end of file
diff --git a/library/ajax/index_data.php b/library/ajax/index_data.php
index a995a094..856361d5 100644
--- a/library/ajax/index_data.php
+++ b/library/ajax/index_data.php
@@ -132,7 +132,7 @@ switch($mode)
break;
default:
- $this->ajax_die('Invalid mode: ' . htmlCHR($mode));
+ $this->ajax_die('Invalid mode');
}
$this->response['html'] = $html;
diff --git a/library/ajax/manage_admin.php b/library/ajax/manage_admin.php
index 1437a0da..6f11a3d9 100644
--- a/library/ajax/manage_admin.php
+++ b/library/ajax/manage_admin.php
@@ -113,7 +113,7 @@ switch ($mode)
default:
- $this->ajax_die('Invalid mode: ' . htmlCHR($mode));
+ $this->ajax_die('Invalid mode');
}
$this->response['mode'] = $mode;
\ No newline at end of file
diff --git a/library/ajax/manage_user.php b/library/ajax/manage_user.php
index 0b2ce371..c13263a4 100644
--- a/library/ajax/manage_user.php
+++ b/library/ajax/manage_user.php
@@ -81,7 +81,7 @@ switch ($mode)
default:
- $this->ajax_die('Invalid mode: ' . htmlCHR($mode));
+ $this->ajax_die('Invalid mode');
}
$this->response['mode'] = $mode;
diff --git a/library/ajax/mod_action.php b/library/ajax/mod_action.php
index 0446be60..7ae9d52a 100644
--- a/library/ajax/mod_action.php
+++ b/library/ajax/mod_action.php
@@ -131,5 +131,5 @@ switch ($mode)
break;
default:
- $this->ajax_die('Invalid mode: ' . htmlCHR($mode));
+ $this->ajax_die('Invalid mode');
}
diff --git a/library/ajax/sitemap.php b/library/ajax/sitemap.php
index 9ad957ca..d573d352 100644
--- a/library/ajax/sitemap.php
+++ b/library/ajax/sitemap.php
@@ -39,7 +39,7 @@ switch ($mode)
break;
default:
- $this->ajax_die('Invalid mode: ' . htmlCHR($mode));
+ $this->ajax_die('Invalid mode');
}
$this->response['html'] = $html;
diff --git a/library/ajax/topic_tpl.php b/library/ajax/topic_tpl.php
index 6c8c11f7..fdc36634 100644
--- a/library/ajax/topic_tpl.php
+++ b/library/ajax/topic_tpl.php
@@ -154,7 +154,7 @@ switch ($mode)
// ошибочный $mode
default:
- $this->ajax_die('Invalid mode: ' . htmlCHR($mode));
+ $this->ajax_die("invalid mode: $mode");
}
// возможный дубль названия шаблона
diff --git a/library/ajax/user_register.php b/library/ajax/user_register.php
index f238162c..25b9ba13 100644
--- a/library/ajax/user_register.php
+++ b/library/ajax/user_register.php
@@ -68,7 +68,7 @@ switch($mode)
break;
default:
- $this->ajax_die('Invalid mode: ' . htmlCHR($mode));
+ $this->ajax_die('Invalid mode');
}
$this->response['html'] = $html;
diff --git a/modcp.php b/modcp.php
index 65870575..25e97490 100644
--- a/modcp.php
+++ b/modcp.php
@@ -846,7 +846,7 @@ switch ($mode)
break;
default:
- bb_die('Invalid action: ' . htmlCHR($mode));
+ bb_die('invalid action');
break;
}
diff --git a/profile.php b/profile.php
index 58c40a5f..244e18f3 100644
--- a/profile.php
+++ b/profile.php
@@ -46,5 +46,5 @@ switch ($mode)
break;
default:
- bb_die('Invalid mode: ' . htmlCHR($mode));
+ bb_die('Invalid mode');
}
\ No newline at end of file
diff --git a/styles/templates/admin/admin_board.tpl b/styles/templates/admin/admin_board.tpl
index 4ef14ec6..bd3c1580 100644
--- a/styles/templates/admin/admin_board.tpl
+++ b/styles/templates/admin/admin_board.tpl
@@ -42,44 +42,44 @@
& - + {L_ACTS_LOG_DAYS_BACK}
diff --git a/styles/templates/admin/admin_rebuild_search.tpl b/styles/templates/admin/admin_rebuild_search.tpl index 28035eee..f826c845 100644 --- a/styles/templates/admin/admin_rebuild_search.tpl +++ b/styles/templates/admin/admin_rebuild_search.tpl @@ -58,7 +58,7 @@ function swap_values()