Mercurial > kallithea
changeset 6557:2f9313074853
controllers: remove empty __before__ methods
__before__ methods that only call the super __before__ method are redundant
and can be removed. The super's method will be called directly.
author | Thomas De Schampheleire <thomas.de.schampheleire@gmail.com> |
---|---|
date | Wed, 15 Mar 2017 21:00:40 +0100 |
parents | a9e776515d8d |
children | 4517e212f09a |
files | kallithea/controllers/followers.py kallithea/controllers/forks.py kallithea/controllers/home.py kallithea/controllers/login.py kallithea/controllers/search.py kallithea/controllers/summary.py |
diffstat | 6 files changed, 0 insertions(+), 18 deletions(-) [+] |
line wrap: on
line diff
--- a/kallithea/controllers/followers.py Sun Jan 15 20:49:23 2017 +0100 +++ b/kallithea/controllers/followers.py Wed Mar 15 21:00:40 2017 +0100 @@ -40,9 +40,6 @@ class FollowersController(BaseRepoController): - def __before__(self): - super(FollowersController, self).__before__() - @LoginRequired() @HasRepoPermissionLevelDecorator('read') def followers(self, repo_name):
--- a/kallithea/controllers/forks.py Sun Jan 15 20:49:23 2017 +0100 +++ b/kallithea/controllers/forks.py Wed Mar 15 21:00:40 2017 +0100 @@ -52,9 +52,6 @@ class ForksController(BaseRepoController): - def __before__(self): - super(ForksController, self).__before__() - def __load_defaults(self): if HasPermissionAny('hg.create.write_on_repogroup.true')(): repo_group_perm_level = 'write'
--- a/kallithea/controllers/home.py Sun Jan 15 20:49:23 2017 +0100 +++ b/kallithea/controllers/home.py Wed Mar 15 21:00:40 2017 +0100 @@ -45,9 +45,6 @@ class HomeController(BaseController): - def __before__(self): - super(HomeController, self).__before__() - def about(self): return render('/about.html')
--- a/kallithea/controllers/login.py Sun Jan 15 20:49:23 2017 +0100 +++ b/kallithea/controllers/login.py Wed Mar 15 21:00:40 2017 +0100 @@ -53,9 +53,6 @@ class LoginController(BaseController): - def __before__(self): - super(LoginController, self).__before__() - def _validate_came_from(self, came_from, _re=re.compile(r"/(?!/)[-!#$%&'()*+,./:;=?@_~0-9A-Za-z]*$")): """Return True if came_from is valid and can and should be used.
--- a/kallithea/controllers/search.py Sun Jan 15 20:49:23 2017 +0100 +++ b/kallithea/controllers/search.py Wed Mar 15 21:00:40 2017 +0100 @@ -49,9 +49,6 @@ class SearchController(BaseRepoController): - def __before__(self): - super(SearchController, self).__before__() - @LoginRequired() def index(self, repo_name=None): c.repo_name = repo_name
--- a/kallithea/controllers/summary.py Sun Jan 15 20:49:23 2017 +0100 +++ b/kallithea/controllers/summary.py Wed Mar 15 21:00:40 2017 +0100 @@ -62,9 +62,6 @@ class SummaryController(BaseRepoController): - def __before__(self): - super(SummaryController, self).__before__() - def __get_readme_data(self, db_repo): repo_name = db_repo.repo_name log.debug('Looking for README file')