Skip to content
  • Georges Racinet's avatar
    multi-vcs: validate Project vcs_type against Application Settings · e90fbe3ee00f
    Georges Racinet authored
    Now that we have the `vcs_types` Application Settings field,
    we use it to enforce upon Project creation that the selected
    `vcs_type` is among them.
    
    This validation has to be done by a separate method in order
    to access the `CurrentSettings` object.
    
    Also, we've considered making the default value for `vcs_type` in
    `CreateService` not to be the library-level default, so that
    explicitely passing a value is never required, even in the case where
    the library default is not allowed by Application Settings, but
    finally decided that failing with an explicit message in that case
    was better than such magic. Note also that the Web UI will always
    pass a value, so this case is in practice for API calls only.
    e90fbe3ee00f