I fucking hate it

This commit is contained in:
bytedream 2022-06-08 14:18:20 +02:00
parent 223459526e
commit 69d2e10362

View file

@ -67,10 +67,6 @@ func loginCredentials(user, password string) error {
return err return err
} }
if err = os.WriteFile(filepath.Join(os.TempDir(), ".crunchy"), []byte(c.SessionID), 0600); err != nil {
return err
}
if loginPersistentFlag { if loginPersistentFlag {
if configDir, err := os.UserConfigDir(); err != nil { if configDir, err := os.UserConfigDir(); err != nil {
return fmt.Errorf("could not save credentials persistent: %w", err) return fmt.Errorf("could not save credentials persistent: %w", err)
@ -135,7 +131,8 @@ func loginCredentials(user, password string) error {
"To encrypt it, use the `--encrypt` flag", filepath.Join(configDir, "crunchyroll-go", "crunchy")) "To encrypt it, use the `--encrypt` flag", filepath.Join(configDir, "crunchyroll-go", "crunchy"))
} }
} }
}
if err = os.WriteFile(filepath.Join(os.TempDir(), ".crunchy"), []byte(c.EtpRt), 0600); err != nil { if err = os.WriteFile(filepath.Join(os.TempDir(), ".crunchy"), []byte(c.EtpRt), 0600); err != nil {
return err return err
} }