Skip to content

Commit

Permalink
Merge pull request #1448 from cozy/upload-queue-errors
Browse files Browse the repository at this point in the history
  • Loading branch information
ptbrowne authored Apr 24, 2020
2 parents a2623e4 + 7a3b91d commit 3b13cf5
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
12 changes: 12 additions & 0 deletions react/UploadQueue/Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,18 @@ const data = {
queue: [{
file: { name: 'Photo.jpg', type: 'file' },
status: 'created'
}, {
file: { name: 'Photo - conflict error.jpg', type: 'file' },
status: 'conflict'
}, {
file: { name: 'Photo - quota error.jpg', type: 'file' },
status: 'quota'
}, {
file: { name: 'Photo - network error.jpg', type: 'file' },
status: 'network'
}, {
file: { name: 'Photo - generic failure error.jpg', type: 'file' },
status: 'failed'
}, {
file: { name: 'File with a very long name - really long - 2020/04/16.txt', type: 'file' },
progress: {
Expand Down
4 changes: 2 additions & 2 deletions react/UploadQueue/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ const CONFLICT = 'conflict'
const QUOTA = 'quota'
const NETWORK = 'network'
const DONE_STATUSES = [CREATED, UPDATED]
const ERROR_STATUSES = [CONFLICT, NETWORK, QUOTA]
const ERROR_STATUSES = [CONFLICT, NETWORK, QUOTA, FAILED]

export const uploadStatus = {
CANCEL,
Expand Down Expand Up @@ -119,7 +119,7 @@ const Item = translate()(
statusIcon = (
<Icon className="u-ml-half" icon="check" color={palette['emerald']} />
)
} else {
} else if (statusToUse === PENDING) {
statusIcon = <Pending />
}

Expand Down

0 comments on commit 3b13cf5

Please sign in to comment.