aboutsummaryrefslogtreecommitdiffhomepage
path: root/inc/poche/Poche.class.php
diff options
context:
space:
mode:
Diffstat (limited to 'inc/poche/Poche.class.php')
-rwxr-xr-xinc/poche/Poche.class.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/inc/poche/Poche.class.php b/inc/poche/Poche.class.php
index c59973f3..85dd3848 100755
--- a/inc/poche/Poche.class.php
+++ b/inc/poche/Poche.class.php
@@ -72,7 +72,7 @@ class Poche
72 72
73 # l10n 73 # l10n
74 $language = $this->user->getConfigValue('language'); 74 $language = $this->user->getConfigValue('language');
75 putenv('LC_ALL=' . $language); 75 @putenv('LC_ALL=' . $language);
76 setlocale(LC_ALL, $language); 76 setlocale(LC_ALL, $language);
77 bindtextdomain($language, LOCALE); 77 bindtextdomain($language, LOCALE);
78 textdomain($language); 78 textdomain($language);
@@ -241,12 +241,12 @@ class Poche
241 $filter = new Twig_SimpleFilter('getReadingTime', 'Tools::getReadingTime'); 241 $filter = new Twig_SimpleFilter('getReadingTime', 'Tools::getReadingTime');
242 $this->tpl->addFilter($filter); 242 $this->tpl->addFilter($filter);
243 } 243 }
244 244
245 public function createNewUser() { 245 public function createNewUser() {
246 if (isset($_GET['newuser'])){ 246 if (isset($_GET['newuser'])){
247 if ($_POST['newusername'] != "" && $_POST['password4newuser'] != ""){ 247 if ($_POST['newusername'] != "" && $_POST['password4newuser'] != ""){
248 $newusername = filter_var($_POST['newusername'], FILTER_SANITIZE_STRING); 248 $newusername = filter_var($_POST['newusername'], FILTER_SANITIZE_STRING);
249 if (!$this->store->userExists($newusername)){ 249 if (!$this->store->userExists($newusername)){
250 if ($this->store->install($newusername, Tools::encodeString($_POST['password4newuser'] . $newusername))) { 250 if ($this->store->install($newusername, Tools::encodeString($_POST['password4newuser'] . $newusername))) {
251 Tools::logm('The new user '.$newusername.' has been installed'); 251 Tools::logm('The new user '.$newusername.' has been installed');
252 $this->messages->add('s', sprintf(_('The new user %s has been installed. Do you want to <a href="?logout">logout ?</a>'),$newusername)); 252 $this->messages->add('s', sprintf(_('The new user %s has been installed. Do you want to <a href="?logout">logout ?</a>'),$newusername));
@@ -265,7 +265,7 @@ class Poche
265 } 265 }
266 } 266 }
267 } 267 }
268 268
269 public function deleteUser(){ 269 public function deleteUser(){
270 if (isset($_GET['deluser'])){ 270 if (isset($_GET['deluser'])){
271 if ($this->store->listUsers() > 1) { 271 if ($this->store->listUsers() > 1) {