mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-21 13:54:02 -07:00
Passkey rework 🔫 (#839)
* WIP: Passkey rework 🔫
* Update tracker.php
* Update Torrent.php
* Update Torrent.php
* Update displaying_torrent.php
* Update viewforum.php
* Update Torrent.php
* Update functions.php
* Update functions.php
* Updated
* Update config.php
* Update functions.php
* Update usercp_viewprofile.tpl
* Update usercp_viewprofile.tpl
* Updated
* Updated
* Update usercp_viewprofile.tpl
* Update usercp_viewprofile.tpl
* Update displaying_torrent.php
This commit is contained in:
parent
3288d905ac
commit
9ba9ca2b61
13 changed files with 88 additions and 52 deletions
|
@ -16,7 +16,9 @@ global $userdata, $lang;
|
|||
$req_uid = (int)$this->request['user_id'];
|
||||
|
||||
if ($req_uid == $userdata['user_id'] || IS_ADMIN) {
|
||||
if (empty($this->request['confirmed'])) {
|
||||
$first_creation = !\TorrentPier\Legacy\Torrent::getPasskey($req_uid);
|
||||
|
||||
if (empty($this->request['confirmed']) && !$first_creation) {
|
||||
$this->prompt_for_confirm($lang['BT_GEN_PASSKEY_NEW']);
|
||||
}
|
||||
|
||||
|
@ -26,6 +28,7 @@ if ($req_uid == $userdata['user_id'] || IS_ADMIN) {
|
|||
|
||||
\TorrentPier\Legacy\Torrent::tracker_rm_user($req_uid);
|
||||
|
||||
$this->response['first_creation'] = $first_creation;
|
||||
$this->response['passkey'] = $passkey;
|
||||
} else {
|
||||
$this->ajax_die($lang['NOT_AUTHORISED']);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue