Indefero

Indefero Commit Details


Date:2011-02-09 09:35:50 (13 years 10 months ago)
Author:Patrick Georgi
Branch: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, release-1.1, release-1.2, release-1.3
Commit:38e6e4f8d390cec241a66186bd6f48f29fa29007
Parents: dfa223b39e61d381b2117c4505437b4642a3c156
Message:Use all registered email addresses to map Scm users to IDF users.

Changes:

File differences

src/IDF/Scm/Git.php
271271
272272
273273
274
275
276
277
278
279
274
275
276
277
280278
281
279
282280
283281
284282
if (!preg_match('/<(.*)>/', $author, $match)) {
return null;
}
foreach (array('email', 'login') as $what) {
$sql = new Pluf_SQL($what.'=%s', array($match[1]));
$users = Pluf::factory('Pluf_User')->getList(array('filter'=>$sql->gen()));
if ($users->count() > 0) {
return $users[0];
}
$sql = new Pluf_SQL('login=%s', array($match[1]));
$users = Pluf::factory('Pluf_User')->getList(array('filter'=>$sql->gen()));
if ($users->count() > 0) {
return $users[0];
}
return null;
return Pluf::factory('IDF_EmailAddress')->get_user_for_email_address($match[1]);
}
public static function getAnonymousAccessUrl($project, $commit=null)
src/IDF/Scm/Mercurial.php
6767
6868
6969
70
71
72
70
7371
7472
7573
if (!preg_match('/<(.*)>/', $author, $match)) {
return null;
}
$sql = new Pluf_SQL('email=%s', array($match[1]));
$users = Pluf::factory('Pluf_User')->getList(array('filter'=>$sql->gen()));
return ($users->count() > 0) ? $users[0] : null;
return Pluf::factory('IDF_EmailAddress')->get_user_for_email_address($match[1]);
}
public function getMainBranch()
src/IDF/Scm/Monotone.php
400400
401401
402402
403
404
405
406
407
408
403
404
405
406
409407
410
408
411409
412410
413411
if (!preg_match('/([^ ]+@[^ ]+)/', $author, $match)) {
return null;
}
foreach (array('email', 'login') as $what) {
$sql = new Pluf_SQL($what.'=%s', array($match[1]));
$users = Pluf::factory('Pluf_User')->getList(array('filter'=>$sql->gen()));
if ($users->count() > 0) {
return $users[0];
}
$sql = new Pluf_SQL('login=%s', array($match[1]));
$users = Pluf::factory('Pluf_User')->getList(array('filter'=>$sql->gen()));
if ($users->count() > 0) {
return $users[0];
}
return null;
return Pluf::factory('IDF_EmailAddress')->get_user_for_email_address($match[1]);
}
/**

Archive Download the corresponding diff file

Page rendered in 0.08092s using 13 queries.