Giter Club home page Giter Club logo

Comments (4)

andymitchell avatar andymitchell commented on September 25, 2024 2

+1

In local development, I manually deleted/reset the database while still logged in, and thereafter could not log out using supabase.auth.signOut in the client.

It returned 403 forbidden every time.

Eventually, I cleared the session from LocalStorage in the browser.

from auth.

amadeus avatar amadeus commented on September 25, 2024

I too seem to be hitting this, feels like a recent change that caused it

from auth.

SebasScript avatar SebasScript commented on September 25, 2024

As a work around deleting the cookies for the site will logout the user

default function deleteAllCookies() {
  var cookies = document.cookie; // Get all cookies as a single string
  var allCookies = cookies.split(";"); // Split into individual cookies

  for (var i = 0; i < allCookies.length; i++) {
    var cookie = allCookies[i];
    var eqPos = cookie.indexOf("="); // Find the first '='
    var name = eqPos > -1 ? cookie.substring(0, eqPos) : cookie; // Extract the cookie name 
    document.cookie = name + "=;expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/"; // Set cookie to expire in the past
  }
}

this is going to remove all cookies for the site by setting their expiry date into the past. This simply removes all cookies. One could also remove specifically the Supabase cookies. Can call this after deleting the user instead of the supabase.tuh.signOut().

from auth.

MatheusAltrao avatar MatheusAltrao commented on September 25, 2024

i am a admin account and i want delete a user from auth with supabase.auth.admin.deleteUser(id) and i can, but every account delete i am redirect to login

from auth.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.