mirror of
https://github.com/balena-io/etcher.git
synced 2025-04-24 15:27:17 +00:00
Merge pull request #199 from resin-io/misc/analytics-restart
Move "Restart" event log to FinishController
This commit is contained in:
commit
ee2fd2a91c
@ -88,8 +88,6 @@ app.controller('AppController', function(
|
||||
this.writer = ImageWriterService;
|
||||
this.scanner = DriveScannerService;
|
||||
|
||||
AnalyticsService.logEvent('Restart');
|
||||
|
||||
NotifierService.subscribe($scope, 'image-writer:state', function(state) {
|
||||
AnalyticsService.log(`Progress: ${state.progress}% at ${state.speed} MB/s`);
|
||||
|
||||
@ -210,12 +208,19 @@ app.controller('NavigationController', function($state) {
|
||||
this.open = shell.openExternal;
|
||||
});
|
||||
|
||||
app.controller('FinishController', function($state, SelectionStateService, SettingsService, ImageWriterService) {
|
||||
app.controller('FinishController', function(
|
||||
$state,
|
||||
SelectionStateService,
|
||||
SettingsService,
|
||||
ImageWriterService,
|
||||
AnalyticsService
|
||||
) {
|
||||
this.settings = SettingsService.data;
|
||||
|
||||
this.restart = function(options) {
|
||||
SelectionStateService.clear(options);
|
||||
ImageWriterService.resetState();
|
||||
AnalyticsService.logEvent('Restart', options);
|
||||
$state.go('main');
|
||||
};
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user