Skip to content

Commit

Permalink
fix backups again
Browse files Browse the repository at this point in the history
  • Loading branch information
arguablykomodo committed Oct 8, 2018
1 parent 277bd2c commit 91d2626
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions install.go
Original file line number Diff line number Diff line change
Expand Up @@ -237,12 +237,12 @@ func install(profilePath string, generateUUIDs bool, setTheme bool) (string, err
}
}

err = backUp(userJs)
if err != nil {
return "Couldn't backup user.js", err
}

if !strings.Contains(string(userJsContent), darkThemeConfig) {
err = backUp(userJs)
if err != nil {
return "Couldn't backup user.js", err
}

userJsContent = append(userJsContent, []byte(darkThemeConfig)...)

if err := ioutil.WriteFile(userJs, userJsContent, 0644); err != nil {
Expand Down

0 comments on commit 91d2626

Please sign in to comment.