ajenti / ajenti

Consider removing the commented out code block PY-W0069
Anti-pattern
Major
6 months ago2 years old
Consider removing the commented out code block
 7from jadi import component
 8
 9from aj.api.http import get, HttpPlugin
10# from aj.auth import authorize11from aj.api.endpoint import endpoint
12import aj
13import gevent
Consider removing the commented out code block
15        self.context = context
16
17    @get(r'/api/softraid/arrays')
18    # @authorize('softraid:show')19    @endpoint(api=True)
20    def handle_api_get_softraid(self, http_context):
21        """
Consider removing the commented out code block
 5from jadi import component
 6
 7from aj.api.http import get, HttpPlugin
 8# from aj.auth import authorize 9from aj.api.endpoint import endpoint
10from aj.plugins.softraid.softraid import RAIDManager
11
Consider removing the commented out code block
 1from jadi import component
 2
 3# from aj.auth import PermissionProvider 4from aj.plugins.core.api.sidebar import SidebarItemProvider
 5
 6
Consider removing the commented out code block
118    """
119
120    ### Is it necessary to do something else ?
121    # if subprocess.call(['which', 'ifdown']) == 0:122        # subprocess.check_call(['ifdown', iface])
123    subprocess.check_call(['ip', 'link', 'set', iface, 'down'])