Skip to content

Commit 63c1dda

Browse files
committed
fix(server) maybe
1 parent 8817122 commit 63c1dda

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

client/edward.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -548,7 +548,7 @@ Edward.prototype._onDrop = function(event) {
548548

549549
event.preventDefault();
550550

551-
const files = [...event.dataTransfer.files];
551+
const files = Array.from(event.dataTransfer.files);
552552

553553
for (const file of files) {
554554
const reader = new FileReader();

server/index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ const maybe = (fn) => {
2323
if (isFn(fn))
2424
return fn();
2525

26-
return data;
26+
return fn;
2727

2828
};
2929

@@ -138,7 +138,7 @@ function _restboxFn({root, dropbox, dropboxToken}, req, res, next) {
138138
return next();
139139

140140
const {url} = req;
141-
const api = '/api/v1';
141+
const prefix = '/api/v1';
142142
const indexOf = url.indexOf.bind(url);
143143
const not = (fn) => (a) => !fn(a);
144144
const is = [
@@ -149,7 +149,7 @@ function _restboxFn({root, dropbox, dropboxToken}, req, res, next) {
149149
return next();
150150

151151
const middle = restbox({
152-
prefix: api,
152+
prefix,
153153
token: dropboxToken,
154154
root: maybe(root),
155155
});

0 commit comments

Comments
 (0)