🐛 Fixed confusing messaging around .yml extension being allowed for routes.yaml uploads (#1140)

no issue

The server never supported uploading .yml files

* updated uploader `invalid extension` error message to be more abstract
* fixed routes uploader validation allowing .yml files
This commit is contained in:
Vikas Potluri 2019-04-03 13:54:05 -05:00 committed by Kevin Ansfield
parent 4ce8a72c98
commit a5bfd36168
3 changed files with 3 additions and 3 deletions

View File

@ -181,7 +181,7 @@ export default Component.extend({
if (!extension || extensions.indexOf(extension.toLowerCase()) === -1) {
let validExtensions = `.${extensions.join(', .').toUpperCase()}`;
return `The image type you uploaded is not supported. Please use ${validExtensions}`;
return `The file type you uploaded is not supported. Please use ${validExtensions}`;
}
return true;

View File

@ -26,7 +26,7 @@ const IMPORT_MIME_TYPES = [
const JSON_EXTENSION = ['json'];
const JSON_MIME_TYPE = ['application/json'];
const YAML_EXTENSION = ['yml', 'yaml'];
const YAML_EXTENSION = ['yaml'];
const YAML_MIME_TYPE = [
'text/vnd.yaml',
'application/vnd.yaml',

View File

@ -307,7 +307,7 @@
{{/if}}
</span>
</button>
<span><a href="#" {{action "downloadFile" "settings/routes/yaml"}} data-test-link="download-routes">Download current routes.yml</a></span>
<span><a href="#" {{action "downloadFile" "settings/routes/yaml"}} data-test-link="download-routes">Download current routes.yaml</a></span>
{{/if}}
<div style="display:none">