projects
/
platal.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Don't force platal core to be in core/ directory
[platal.git]
/
classes
/
pluser.php
diff --git
a/classes/pluser.php
b/classes/pluser.php
index
746ec59
..
9fa6a5d
100644
(file)
--- a/
classes/pluser.php
+++ b/
classes/pluser.php
@@
-1,6
+1,6
@@
<?php
/***************************************************************************
<?php
/***************************************************************************
- * Copyright (C) 2003-201
0
Polytechnique.org *
+ * Copyright (C) 2003-201
1
Polytechnique.org *
* http://opensource.polytechnique.org/ *
* *
* This program is free software; you can redistribute it and/or modify *
* http://opensource.polytechnique.org/ *
* *
* This program is free software; you can redistribute it and/or modify *
@@
-367,7
+367,7
@@
abstract class PlUser implements PlUserInterface
$list[$i] = $login;
}
}
$list[$i] = $login;
}
}
- return
$list
;
+ return
array_unique($list)
;
}
return null;
}
}
return null;
}
@@
-403,7
+403,7
@@
abstract class PlUser implements PlUserInterface
private static function stripBadChars($text)
{
private static function stripBadChars($text)
{
- return str_replace(array(' ', "'"
), array('-', '
'),
+ return str_replace(array(' ', "'"
, '+'), array('-', '', '_
'),
strtolower(stripslashes(replace_accent(trim($text)))));
}
strtolower(stripslashes(replace_accent(trim($text)))));
}
@@
-426,7
+426,7
@@
abstract class PlUser implements PlUserInterface
public static function makeHrid($firstname, $lastname, $category)
{
$cat = self::stripBadChars($category);
public static function makeHrid($firstname, $lastname, $category)
{
$cat = self::stripBadChars($category);
- if (!cat) {
+ if (!
$
cat) {
Platal::page()->kill("$category is not a suitable category.");
}
Platal::page()->kill("$category is not a suitable category.");
}