Indefero

Indefero Commit Details


Date:2009-01-02 04:43:15 (15 years 11 months ago)
Author:Loic d'Anterroches
Branch:dev, develop, feature-issue_links, feature.better-home, feature.content-md5, feature.diff-whitespace, feature.download-md5, feature.issue-links, feature.issue-of-others, feature.issue-summary, feature.search-filter, feature.webrepos, feature.wiki-default-page, master, release-1.1, release-1.2, release-1.3
Commit:76cf64369d60bf3692ec72c6ca0cc60700d28e66
Parents: 404e2cd150c930108bb65961e9278d7e9464b37d
Message:Inforce the rule to have only letters and digits in the login.

Changes:

File differences

src/IDF/Form/Register.php
6868
6969
7070
71
72
73
7174
7275
7376
public function clean_login()
{
$this->cleaned_data['login'] = mb_strtolower(trim($this->cleaned_data['login']));
if (preg_match('/[^A-Za-z0-9]/', $this->cleaned_data['login'])) {
throw new Pluf_Form_Invalid(sprintf(__('The login "%s" can only contain letters and digits.'), $this->cleaned_data['login']));
}
$guser = new Pluf_User();
$sql = new Pluf_SQL('login=%s', $this->cleaned_data['login']);
if ($guser->getCount(array('filter' => $sql->gen())) > 0) {

Archive Download the corresponding diff file

Page rendered in 0.07762s using 13 queries.