Changeset - 2f9313074853
[Not reviewed]
default
0 6 0
Thomas De Schampheleire - 9 years ago 2017-03-15 21:00:40
thomas.de.schampheleire@gmail.com
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.
6 files changed with 0 insertions and 18 deletions:
0 comments (0 inline, 0 general)
kallithea/controllers/followers.py
Show inline comments
 
@@ -40,9 +40,6 @@ log = logging.getLogger(__name__)
 

	
 
class FollowersController(BaseRepoController):
 

	
 
    def __before__(self):
 
        super(FollowersController, self).__before__()
 

	
 
    @LoginRequired()
 
    @HasRepoPermissionLevelDecorator('read')
 
    def followers(self, repo_name):
kallithea/controllers/forks.py
Show inline comments
 
@@ -52,9 +52,6 @@ log = logging.getLogger(__name__)
 

	
 
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'
kallithea/controllers/home.py
Show inline comments
 
@@ -45,9 +45,6 @@ log = logging.getLogger(__name__)
 

	
 
class HomeController(BaseController):
 

	
 
    def __before__(self):
 
        super(HomeController, self).__before__()
 

	
 
    def about(self):
 
        return render('/about.html')
 

	
kallithea/controllers/login.py
Show inline comments
 
@@ -53,9 +53,6 @@ log = logging.getLogger(__name__)
 

	
 
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.
kallithea/controllers/search.py
Show inline comments
 
@@ -49,9 +49,6 @@ log = logging.getLogger(__name__)
 

	
 
class SearchController(BaseRepoController):
 

	
 
    def __before__(self):
 
        super(SearchController, self).__before__()
 

	
 
    @LoginRequired()
 
    def index(self, repo_name=None):
 
        c.repo_name = repo_name
kallithea/controllers/summary.py
Show inline comments
 
@@ -62,9 +62,6 @@ README_FILES = [''.join([x[0][0], x[1][0
 

	
 
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')
0 comments (0 inline, 0 general)