                 else
                     # Create parent folder and touch file
                     mkdirp path.join(remoteConfig.path, doc.path), () ->
-                        touch name, () ->
-                            fs.utimes name,
-                                new Date(doc.creationDate),
-                                new Date(doc.lastModification),
-                                () ->
-                                    callback()
+                        # Find if binary is already downloaded
+                        db.get doc.binary.file.id, (err, binaryDoc) ->
+                            if binaryDoc?
+                                # And move it to the right path
+                                fs.rename binaryDoc.path, name, () ->
+                                    binaryDoc.path = name
+                                    db.put binaryDoc, (err, res) ->
+                                        fs.utimes name,
+                                            new Date(doc.creationDate),
+                                            new Date(doc.lastModification),
+                                            callback
+                            else
+                                # Otherwise touch the file
+                                touch name, () ->
+                                    fs.utimes name,
+                                        new Date(doc.creationDate),
+                                        new Date(doc.lastModification),
+                                        callback
         , callback
 
 

                        return callback()

                else
                    newId = uuid.v4().split('-').join('')
                    log.info "Creating file doc: #{relativePath}"
                    db.put doc, newId, (err, res) ->

                            callback()
                        else
                            # Fetch binary via CouchDB API
                            log.info "Downloading binary: #{path.join doc.path, doc.name}"
                            client.saveFile binaryUri, binaryPath, (err, res, body) ->
                                console.log err if err?

