Use context instead of static access

This commit is contained in:
Vincent Petry 2014-07-09 12:09:10 +02:00
parent 1e65def248
commit 423cb53e14

View File

@ -46,8 +46,8 @@ var odfViewer = {
} }
}, },
onEdit : function(){ onEdit : function(fileName, context){
var fileId = OCA.Files.fileActions.currentFile.parent().attr('data-id'); var fileId = context.$file.attr('data-id');
window.location = OC.linkTo('documents', 'index.php') + '#' + fileId; window.location = OC.linkTo('documents', 'index.php') + '#' + fileId;
}, },