add translation for writing files in comitium.json (I didn't notice them before)
This commit is contained in:
+12
-3
@@ -118,17 +118,26 @@ func main() {
|
||||
}
|
||||
err = core.Data.WriteSubs(dataPath)
|
||||
if err != nil {
|
||||
fmt.Fprintf(os.Stderr, "Error saving subscriptions: %v\n", err)
|
||||
fmt.Fprintf(os.Stderr, core.TranslateString(
|
||||
"%s\n", "errors.saving",
|
||||
&localizations.Replacements{"file": "subscriptions.gmi", "error": err},
|
||||
))
|
||||
os.Exit(1)
|
||||
}
|
||||
err = core.Data.WriteFeed(dataPath)
|
||||
if err != nil {
|
||||
fmt.Fprintf(os.Stderr, "Error writing feed: %v\n", err)
|
||||
fmt.Fprintf(os.Stderr, core.TranslateString(
|
||||
"%s\n", "errors.saving",
|
||||
&localizations.Replacements{"file": "feed.gmi", "error": err},
|
||||
))
|
||||
os.Exit(1)
|
||||
}
|
||||
err = core.Data.WriteJSON(dataPath)
|
||||
if err != nil {
|
||||
fmt.Fprintf(os.Stderr, "Error saving subscriptions json: %v\n", err)
|
||||
fmt.Fprintf(os.Stderr, core.TranslateString(
|
||||
"%s\n", "errors.saving",
|
||||
&localizations.Replacements{"file": "comtitium.json", "error": err},
|
||||
))
|
||||
os.Exit(1)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user