Skip to content

Commit

Permalink
[Storage] az storage cors add: Allow PATCH for --methods (#22045)
Browse files Browse the repository at this point in the history
  • Loading branch information
evelyn-ys authored Apr 15, 2022
1 parent a1b60cc commit efac3f9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/azure-cli/azure/cli/command_modules/storage/_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -1756,12 +1756,14 @@ def load_arguments(self, _): # pylint: disable=too-many-locals, too-many-statem
options_list='--services', required=False)

with self.argument_context('storage cors add') as c:
t_cors_rule_allowed_methods = self.get_models('CorsRuleAllowedMethodsItem',
resource_type=ResourceType.MGMT_STORAGE)
c.extra('services', validator=get_char_options_validator('bfqt', 'services'), required=True,
options_list='--services')
c.argument('max_age')
c.argument('origins', nargs='+')
c.argument('methods', nargs='+',
arg_type=get_enum_type(['DELETE', 'GET', 'HEAD', 'MERGE', 'POST', 'OPTIONS', 'PUT']))
arg_type=get_enum_type(t_cors_rule_allowed_methods))
c.argument('allowed_headers', nargs='+')
c.argument('exposed_headers', nargs='+')

Expand Down

0 comments on commit efac3f9

Please sign in to comment.