Skip to content

Pressing the OK button twice in quick succesion will load the page.  #7

Description

@ant-ms

As the title says, Pressing the OK button twice in quick succession will load the page even when no login data is entered. When I then reload the page, I get an "unauthorized" though. In the console I get this error: uncaughtException: Error [ERR_STREAM_WRITE_AFTER_END]: write after end.
(no idea why, but this only seems to happen in Firefox (tried an multiple devices))

I've used this piece of code to fix it temporarily:

if (!users.some(({ user, password }) => base64.encode(`${user}:${password}`) == req.headers.authorization.split(" ")[1])) {
  res.end('<html>Unauthorized</html>')
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions