Skip to content

Commit

Permalink
fix build issues
Browse files Browse the repository at this point in the history
  • Loading branch information
dularion committed Feb 7, 2021
1 parent afb2015 commit 1dcc0d3
Showing 1 changed file with 7 additions and 4 deletions.
Expand Up @@ -128,10 +128,11 @@ angular.module('streama').controller('modalFileCtrl', [
apiService.video.removeFile($scope.video.id, file.id).then(function () {
_.remove($scope.video.subtitles, {id: file.id});
alertify.success('Subtitles deleted.');
}).then(() => apiService.subtitle.refreshSubtitles($scope.video.id).then(function (data) {
}).then(function (){
apiService.subtitle.refreshSubtitles($scope.video.id).then(function (data) {
$scope.video.subtitles = data.data;
})
);
});
});
}
});

Expand All @@ -150,7 +151,9 @@ angular.module('streama').controller('modalFileCtrl', [

function setAsDefault(file) {
apiService.subtitle.setDefault(file.id, $scope.video.id).then(function (data) {
video.subtitles.forEach(s => s.isDefault = false);
video.subtitles.forEach(function (s){
s.isDefault = false;
});
file.isDefault = true;
alertify.success('Successfully set by default');
});
Expand Down

0 comments on commit 1dcc0d3

Please sign in to comment.