Remove calls to Profile::getNameTypeId.
authorFlorent Bruneau <florent.bruneau@polytechnique.org>
Sat, 6 Mar 2010 22:20:16 +0000 (23:20 +0100)
committerFlorent Bruneau <florent.bruneau@polytechnique.org>
Sat, 6 Mar 2010 22:20:16 +0000 (23:20 +0100)
Signed-off-by: Florent Bruneau <florent.bruneau@polytechnique.org>
classes/userfilter.php

index ff446a3..3e841da 100644 (file)
@@ -1965,7 +1965,7 @@ class UserFilter extends PlFilter
 
     static public function assertName($name)
     {
-        if (!Profile::getNameTypeId($name)) {
+        if (!DirEnum::getID(DirEnum::NAMETYPES, $name)) {
             Platal::page()->kill('Invalid name type: ' . $name);
         }
     }
@@ -1985,7 +1985,7 @@ class UserFilter extends PlFilter
         if (!is_null($variant) && $variant == 'other') {
             $sub .= $this->option++;
         }
-        $this->pn[$sub] = Profile::getNameTypeId($ft);
+        $this->pn[$sub] = DirEnum::getID(DirEnum::NAMETYPES, $ft);
         return $sub;
     }