public inbox for [email protected]
 help / color / mirror / Atom feed
From: Ammar Faizi <[email protected]>
To: Muhammad Rizki <[email protected]>
Cc: Alviro Iskandar Setiawan <[email protected]>,
	GNU/Weeb Mailing List <[email protected]>
Subject: Re: [PATCH v1 00/10] Relative Path, Delete Avatar, Sidebar, Toast
Date: Sat, 8 Mar 2025 22:18:10 +0700	[thread overview]
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>

[-- Attachment #1: Type: text/plain, Size: 1685 bytes --]

On 3/8/25 2:26 AM, Muhammad Rizki wrote:
> Hello,
> This series fixes relative path, fixes social fields, add delete avatar
> method, change sidebar menu look, change toast message position and
> use richColors.
> 
> Give it a test and let me know if there's any issue, thanks.

I tried to apply it on mail-staging.gnuweeb.org. And it makes the
current active session no longer works. It shows "500 Internal Error".

Checking on network tab, the header it sends is:

     Authorization: Bearer null

Local storage inspection:

JSON.stringify(localStorage)
'{"gwm_token":"null","gwm_token_exp_at":"1742402878","gwm_uinfo":"{\\"id\\":2,\\"full_name\\":\\"Ammar Faizi\\",\\"gender\\":\\"m\\",\\"username\\":\\"ammarfaizi2\\",\\"ext_email\\":\\"[email protected]\\",\\"role\\":\\"admin\\",\\"is_active\\":\\"1\\",\\"socials\\":{\\"github_username\\":\\"ammarfaizi2\\",\\"telegram_username\\":\\"ammarfaizi2\\",\\"twitter_username\\":\\"ammarfaizi2\\",\\"discord_username\\":\\"ammarfaizi2\\"},\\"photo\\":\\"https://mail.gnuweeb.org/api.php?action=fetch_photo&f=5oGoBUc31xCxK%2FFoBUk4B8Nt9ZcZ3f%2B7dwfDIPPf9vYTyh2ziSDL%2Bt1ZJ3lmjnHlQBBsTkAMkQsEGZ2n9sEdnREmFgolrSfQImYLIzLmQ%2Bo%3D\\"}"}'

Take a look at the "gwm_token" here, it's set to "null" as a string.
That seems off. How do you determine if "gwm_token" is empty?

Testing in incognito mode works fine, but for active sessions, it
breaks and doesn't recover automatically. Instead, it continuously
throws a 500 Internal Server Error.

The only way to fix it is by manually clearing localStorage, which
is far from ideal.

The app should immediately log the user out upon receiving a
"401 Unauthorized" response.

-- 
Ammar Faizi

[-- Attachment #2: Screenshot from 2025-03-08 22-05-33.png --]
[-- Type: image/png, Size: 92802 bytes --]

  parent reply	other threads:[~2025-03-08 15:18 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-07 19:26 [PATCH v1 00/10] Relative Path, Delete Avatar, Sidebar, Toast Muhammad Rizki
2025-03-07 19:26 ` [PATCH v1 01/10] fix(svelte): use relative false Muhammad Rizki
2025-03-07 19:26 ` [PATCH v1 02/10] fix(avatar): change avatarImg state to use from auth.user.photo state Muhammad Rizki
2025-03-07 19:26 ` [PATCH v1 03/10] chore(profile): add toUpperCase() on getShortName() Muhammad Rizki
2025-03-07 19:26 ` [PATCH v1 04/10] fix(profile): make social fields default to empty string Muhammad Rizki
2025-03-07 19:26 ` [PATCH v1 05/10] chore(toaster): change toast message position and use richColors Muhammad Rizki
2025-03-07 19:26 ` [PATCH v1 06/10] chore(profile): reset password value on success Muhammad Rizki
2025-03-07 19:26 ` [PATCH v1 07/10] fix(profile-avatar): add delete avatar method Muhammad Rizki
2025-03-07 19:26 ` [PATCH v1 08/10] chore(profile): add space for password confirmation form Muhammad Rizki
2025-03-07 19:26 ` [PATCH v1 09/10] feat(ui): add dropdown-menu and update bits-ui version Muhammad Rizki
2025-03-07 19:26 ` [PATCH v1 10/10] chore(sidebar-menu): change sidebar menu look Muhammad Rizki
2025-03-08 15:18 ` Ammar Faizi [this message]
2025-03-08 15:21   ` [PATCH v1 00/10] Relative Path, Delete Avatar, Sidebar, Toast Muhammad Rizki
2025-03-08 15:28     ` Ammar Faizi
2025-03-08 15:46       ` Muhammad Rizki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    [email protected] \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox