Unverified Commit 58297140 authored by Sebastian Schüpbach's avatar Sebastian Schüpbach
Browse files

fix file type matching


Signed-off-by: Sebastian Schüpbach's avatarSebastian Schüpbach <sebastian.schuepbach@unibas.ch>
parent 8ca071e9
......@@ -50,13 +50,13 @@ class RecordProcessor(fileHandler: DisseminationCopyHandler, fedoraClientWrapper
case (id, Delete, af: AudioFileType, _) =>
errorHandler(fileHandler.deleteAudioCopy(id), id, af, "Delete")
case (id, Create | Update, vf: VideoFileType, data) =>
errorHandler(fileHandler.createImageCopy(data, id), id, vf, "Create/Update")
errorHandler(fileHandler.createVideoCopy(data, id), id, vf, "Create/Update")
case (id, Delete, vf: VideoFileType, _) =>
errorHandler(fileHandler.deleteImageCopy(id), id, vf, "Delete")
errorHandler(fileHandler.deleteVideoCopy(id), id, vf, "Delete")
case (id, Create | Update, i: ImageFileType, data) =>
errorHandler(fileHandler.createVideoCopy(data, id), id, i, "Create/Update")
errorHandler(fileHandler.createImageCopy(data, id), id, i, "Create/Update")
case (id, Delete, i: ImageFileType, _) =>
errorHandler(fileHandler.deleteVideoCopy(id), id, i, "Delete")
errorHandler(fileHandler.deleteImageCopy(id), id, i, "Delete")
case (id, event, ft, _) =>
ProcessFailure(id, ft, event.toString, new Exception)
}).recover {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment