chiark / gitweb /
Change the message for AuthError::Nonexistent.
authorSimon Tatham <anakin@pobox.com>
Wed, 24 Jan 2024 08:48:11 +0000 (08:48 +0000)
committerSimon Tatham <anakin@pobox.com>
Wed, 24 Jan 2024 20:03:12 +0000 (20:03 +0000)
commit540edf3a9ad611eb989986e057451e2f595b8c22
tree1d949daf887fae3c6350137cd4480a06f993dacf
parenta16fe962b12a2ad35fedeee6d8535e098d1aab38
Change the message for AuthError::Nonexistent.

"Not logged in" used to be correct, when we didn't support account
registration. But now the auth file can _exist_ while still being
logged in. So we should be more precise in the translation of this
error code: it really means <cfgdir>/auth is absent in an ENOENT sort
of way.

However, we shouldn't normally _see_ that message: it's one of the few
error cases that we detect programmatically and divert into a handler
for (to wit, the login flow).
src/auth.rs