Merge pull request #3629 from johndela1/master

[MRG+1] rel_has_nofollow: remove redundant if statement
This commit is contained in:
Adrián Chaves 2019-03-15 07:53:23 +01:00 committed by GitHub
commit 2bd5790d9b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -116,7 +116,7 @@ def md5sum(file):
def rel_has_nofollow(rel):
"""Return True if link rel attribute has nofollow type"""
return True if rel is not None and 'nofollow' in rel.split() else False
return rel is not None and 'nofollow' in rel.split()
def create_instance(objcls, settings, crawler, *args, **kwargs):