epsylon3 / torrentflux

TorrentFlux-NG - Based on Torrent Flux B4rt (recent SVN history)
http://epsylon3.github.com/torrentflux
GNU General Public License v2.0
135 stars 58 forks source link

Changing users password/type/offline failing #19

Closed smalla closed 12 years ago

smalla commented 12 years ago

change in /inc/functions/functions.admin.php

1114c1114

-- function updateThisUser($user_id, $org_user_id, $pass1, $userType, $hideOffline) {

++ function updateThisUser($user_id, $org_user_id, $pass1, $userType, $hideOffline, $email_address) { 1126c1126,1127

-- if ($pass1 != "")

++ $rec['email_address'] = $email_address; ++ if ($pass1 != "") { 1127a1129 ++ }

and /inc/iid/admin/updateUser.php 48c48

-- if ((IsUser($org_user_id)) && (!IsUser($user_id)) && ($user_id != '') && ($user_id != $org_user_id) && ($passwordCheck === true)) {

++ if (((IsUser($org_user_id)) && (!IsUser($user_id)) && ($user_id != '') && ($passwordCheck === true)) || (($user_id == $org_user_id) && ($passwordCheck === true)) ) { 56c56

-- @header("location: admin.php");

++ @header("location: admin.php?op=editUser&user_id=".urlencode($user_id)); 58c58

-- } elseif($email_address != "") {

++ } /*elseif($email_address != "") { 62c62

-- }

++ }*/