diff options
| author | syuilo <syuilotan@yahoo.co.jp> | 2017-02-01 09:27:37 +0900 |
|---|---|---|
| committer | syuilo <syuilotan@yahoo.co.jp> | 2017-02-01 09:27:37 +0900 |
| commit | ac661eacc0864eef3ca273f5b18fa9a0014efe84 (patch) | |
| tree | 63fcc0a9eb993a31fb253652f29d88025400c34f /src/api/common | |
| parent | Fix: Add missing semicolon (diff) | |
| download | sharkey-ac661eacc0864eef3ca273f5b18fa9a0014efe84.tar.gz sharkey-ac661eacc0864eef3ca273f5b18fa9a0014efe84.tar.bz2 sharkey-ac661eacc0864eef3ca273f5b18fa9a0014efe84.zip | |
[Server] Remove needless query
Diffstat (limited to 'src/api/common')
| -rw-r--r-- | src/api/common/add-file-to-drive.ts | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/api/common/add-file-to-drive.ts b/src/api/common/add-file-to-drive.ts index 98f3e9635b..b4e3773c19 100644 --- a/src/api/common/add-file-to-drive.ts +++ b/src/api/common/add-file-to-drive.ts @@ -54,11 +54,10 @@ export default ( .digest('hex') as string; if (!force) { - // Check if there is a file with the same hash and same data size (to be safe) + // Check if there is a file with the same hash const much = await DriveFile.findOne({ user_id: user._id, - hash: hash, - datasize: size + hash: hash }); if (much !== null) { |