]> git.mxchange.org Git - friendica.git/commitdiff
Merge pull request #4323 from MrPetovan/bug/fix-removeme-auth
authorMichael Vogel <icarus@dabo.de>
Wed, 24 Jan 2018 17:18:50 +0000 (18:18 +0100)
committerGitHub <noreply@github.com>
Wed, 24 Jan 2018 17:18:50 +0000 (18:18 +0100)
Fix wrong authenticate() parameter type in mod/removeme

1  2 
mod/removeme.php

diff --combined mod/removeme.php
index ac13da2f14696eaed888fe1c2cbb6c4e3a40a97a,d49669ae844ba155b707ad012b4d13e6b751b39d..27d501d66131ed1b253f866c60c4c1a7481529f1
@@@ -1,9 -1,6 +1,9 @@@
  <?php
 -
 +/**
 + * @file mod/removeme.php
 + */
  use Friendica\App;
 +use Friendica\Core\L10n;
  use Friendica\Core\System;
  use Friendica\Model\User;
  
@@@ -29,7 -26,7 +29,7 @@@ function removeme_post(App $a
                return;
        }
  
-       if (User::authenticate($a->user['uid'], trim($_POST['qxz_password']))) {
+       if (User::authenticate($a->user, trim($_POST['qxz_password']))) {
                User::remove($a->user['uid']);
                // NOTREACHED
        }
@@@ -52,10 -49,10 +52,10 @@@ function removeme_content(App $a
        $o .= replace_macros($tpl, [
                '$basedir' => System::baseUrl(),
                '$hash' => $hash,
 -              '$title' => t('Remove My Account'),
 -              '$desc' => t('This will completely remove your account. Once this has been done it is not recoverable.'),
 -              '$passwd' => t('Please enter your password for verification:'),
 -              '$submit' => t('Remove My Account')
 +              '$title' => L10n::t('Remove My Account'),
 +              '$desc' => L10n::t('This will completely remove your account. Once this has been done it is not recoverable.'),
 +              '$passwd' => L10n::t('Please enter your password for verification:'),
 +              '$submit' => L10n::t('Remove My Account')
        ]);
  
        return $o;