simplify commits detection

Signed-off-by: Pierre Mazière <pierre.maziere@gmx.com>
This commit is contained in:
Pierre Mazière 2016-06-26 00:46:41 +02:00
parent 615df56b19
commit ca44ab943a

View file

@ -48,10 +48,7 @@ class GitlabCommitsBridge extends BridgeAbstract{
or $this->returnError('No results for LWNprev', 404); or $this->returnError('No results for LWNprev', 404);
foreach($html->find('li') as $commit){ foreach($html->find('li.commit') as $commit){
if(!in_array('commit',explode(' ',$commit->getAttribute("class")))){
continue;
}
$item = new \Item(); $item = new \Item();
$item->uri=$param['uri']; $item->uri=$param['uri'];