Skip to content

Commit

Permalink
feat: Allow folder separators inside image names
Browse files Browse the repository at this point in the history
BREAKING CHANGE: Images in folders start using `/` as the folder
separator. Previously this was replaced with `__`.
  • Loading branch information
avaly committed Feb 4, 2020
1 parent 379d9ca commit e008663
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion __tests__/buildFolder.test.js
Expand Up @@ -72,7 +72,7 @@ describe('buildFolder', () => {
.post(`/builds/${buildID}/images`, reqBody =>
validateRequestBody(
reqBody,
'subfolder__viswiz-favicon-48',
'subfolder/viswiz-favicon-48',
'viswiz-favicon-48.png'
)
)
Expand Down
3 changes: 1 addition & 2 deletions src/sdk.js
Expand Up @@ -443,8 +443,7 @@ class VisWiz {
name = name
.replace(fullPath, '')
.replace(/^[/\\]/, '')
.replace(/\.png$/i, '')
.replace(/[/\\]/g, '__');
.replace(/\.png$/i, '');

return chain
.then(() => this.createImage(buildID, name, imageFile))
Expand Down

0 comments on commit e008663

Please sign in to comment.