mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
reset the 'failedLoad' state when a new entity is selected
This commit is contained in:
parent
9738703424
commit
a1552aa872
1 changed files with 3 additions and 1 deletions
|
@ -1,9 +1,11 @@
|
|||
define [
|
||||
"base"
|
||||
], (App) ->
|
||||
App.controller "BinaryFileController", ["$scope", ($scope) ->
|
||||
App.controller "BinaryFileController", ["$scope", "$rootScope", ($scope, $rootScope) ->
|
||||
|
||||
$scope.failedLoad = false
|
||||
$rootScope.$on 'entity:selected', () ->
|
||||
$scope.failedLoad = false
|
||||
|
||||
window.sl_binaryFilePreviewError = () =>
|
||||
$scope.failedLoad = true
|
||||
|
|
Loading…
Reference in a new issue