Skip to content
This repository has been archived by the owner on Feb 12, 2024. It is now read-only.

fix(examples): Ensure started prior to adding file #912

Merged
merged 1 commit into from
Jul 15, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions examples/transfer-files/public/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,10 @@ function onDrop (event) {
onDragExit()
$errors.className = 'hidden'
event.preventDefault()
if (!node) {
onError('IPFS must be started before files can be added')
return
}
const dt = event.dataTransfer
const files = dt.files

Expand Down