diff --git a/venus/api/openstack/wsgi.py b/venus/api/openstack/wsgi.py index a90d74c..ef120d9 100644 --- a/venus/api/openstack/wsgi.py +++ b/venus/api/openstack/wsgi.py @@ -1001,7 +1001,7 @@ class Resource(wsgi.Application): project_id = action_args.pop("project_id", None) context = request.environ.get('venus.context') - if (context and project_id and (project_id != context.project_id)): + if context and project_id and (project_id != context.project_id): msg = _("Malformed request url") return Fault(webob.exc.HTTPBadRequest(explanation=msg)) diff --git a/venus/cmd/manage.py b/venus/cmd/manage.py index f1b803a..91cb3ce 100644 --- a/venus/cmd/manage.py +++ b/venus/cmd/manage.py @@ -224,7 +224,6 @@ class GetLogCommands(object): """Get of the venus syslog events.""" entries = int(num_entries) count = 0 - log_file = '' if os.path.exists('/var/log/syslog'): log_file = '/var/log/syslog' elif os.path.exists('/var/log/messages'): @@ -305,7 +304,6 @@ category_opt = cfg.SubCommandOpt('category', def get_arg_string(args): - arg = None if args[0] == '-': # (Note)zhiteng: args starts with FLAGS.oparser.prefix_chars # is optional args. Notice that cfg module takes care of