https://supabase.com/ logo
Join Discord
Powered by
# help
  • j

    Juliรกn

    09/02/2021, 5:53 PM
    @waptik I'm glad that it helped you, inserts are working fine for me
  • r

    richard

    09/02/2021, 5:58 PM
    Yep, I was the one who posted that ๐Ÿ˜…
  • l

    loooke

    09/02/2021, 6:01 PM
    Hey, is there any way to send a session refresh_token with a `from().select()`(supabase-js) query to my database i've got a RLS statement that lets users only see their own content, but I would think sending a refresh token or id or something would be the only right way to do this
  • f

    faaabi s

    09/02/2021, 7:20 PM
    why does gmail flag the confirmtion mails as dangerous and removes all links? xD
  • s

    Scott P

    09/02/2021, 7:32 PM
    https://discord.com/channels/839993398554656828/839993398554656831/882378410960244736
  • w

    wiverson

    09/03/2021, 5:38 AM
    I am doing some testing, and noticed an interesting behavior. I log into my GitHub account using Supabase.js auth. Then I log out. Then I log in with my Twitter account, which has the same email address. What's strange is that I'm seeing the JWT for the GitHub provider come back to my app even when I specify Twitter as the provider. I actually see the app redirect to the Twitter auth page and then bounce back to my app with the GitHub JWT. Is this expected behavior?
  • w

    wiverson

    09/03/2021, 5:39 AM
    Perhaps the system is seeing the Twitter auth come back with the same email as the GitHub profile, so it's then returning that JWT?
  • w

    wiverson

    09/03/2021, 5:39 AM
    Does Supabase do some kind of email coalescing for accounts?
  • h

    hanginglegraise

    09/03/2021, 7:02 AM
    Hi, is there a way to access database usage history? Because my db usage is already at 8mb but I don't remember entering any data except just for playing around
  • f

    Fabian B.

    09/03/2021, 9:44 AM
    @User That's the default data supabase needs I think. I also have an nearly empty project with only a few bytes of table rows in it. but it's also at 8mb.
  • h

    hanginglegraise

    09/03/2021, 9:49 AM
    well that's a bummer, 8mb/500mb is quite noticeable..
  • t

    Tan

    09/03/2021, 9:51 AM
    When a user signs up is it possible to send another field to the database along with username and password
  • f

    Fabian B.

    09/03/2021, 9:51 AM
    @User Kinda, but the 500mb is only for the database, storage and everything is extra. And I think you would have to save A LOT of data to get to 500mb. And then I think it's fair to upgrade.
  • f

    Fabian B.

    09/03/2021, 9:52 AM
    @Tan Not directly at signup, but afterwards, you can create some custom fields for a user. Look at this example: https://supabase.io/docs/reference/javascript/auth-update#update-a-users-metadata
  • h

    hanginglegraise

    09/03/2021, 9:52 AM
    Sure, but I din't say that it's not fair to upgrade, this stuff is gold man
  • h

    hanginglegraise

    09/03/2021, 9:53 AM
    It's just my precious 8mb database storage..
  • f

    Fabian B.

    09/03/2021, 9:54 AM
    @User Absolutely! Maybe someone from the supabase team can answer better, what these 8mb are.
  • t

    Tan

    09/03/2021, 10:01 AM
    @User thanks, I'll take a look at this field
  • f

    faaabi s

    09/03/2021, 10:07 AM
    hey everyone im new to webdev so this probably is a very nooby question. im trying to make a small javascript app where you can create a post as a user (only when authenticated). i have a table "posts" and the following frontend code: const postFunction = (event) => { event.preventDefault() console.log("post") const { data, error } = supabase .from('posts') .insert([ { creator: supabase.auth.user().id, text: document.getElementById('postinput').value } ]) .then(() => { fetchPost(); }) } but like this everyone could change "creator: supabase.auth.user().id," to any user right? so whats the right way to do this (so users can only create post with their own uid)? thanks is advance for helping ๐Ÿ™‚
  • f

    Fabian B.

    09/03/2021, 10:25 AM
    Hey @User Everyone started sometimes, no worries ๐Ÿ™‚ Actually, in theory, this would be true yes. But when you activate RLS (Row Level Security), only the user that's authenticated with this id in your client can create new posts with his/her id. Read more about it here: https://supabase.io/docs/guides/auth#row-level-security
  • s

    silentworks

    09/03/2021, 10:27 AM
    This video released today by @User will help you with this, its a very good explanation of RLS and he is also talking about a blog post scenario

    https://www.youtube.com/watch?v=Ow_Uzedfohkโ–พ

  • m

    moonasalhin

    09/03/2021, 10:47 AM
    Hello! Newbiequestion here. Is it possible to rename properties when doing a select request?
    Copy code
    const { data, error } = await supabase.from('bets').select(`
        stake,
        profiles ( username ),
        events ( fixture )
      `);
    for example rename profiles to profileInfo or something like that ๐Ÿ™‚
    s
    • 2
    • 2
  • m

    moonasalhin

    09/03/2021, 10:49 AM
    guess Im looking for the 'as' equivalency
  • s

    silentworks

    09/03/2021, 10:51 AM
    Try
    Copy code
    sql
    const { data, error } = await supabase.from('bets').select(`
        stake,
        profiles:profileInfo ( username ),
        events ( fixture )
    `);
  • m

    moonasalhin

    09/03/2021, 11:22 AM
    no luck there
  • c

    cataxcab

    09/03/2021, 11:30 AM
    Hi, quick question about the Svelte guide: I'm following this: https://supabase.io/docs/guides/with-svelte My rollup.config.js:
    Copy code
    js
    import { config } from 'dotenv';
    import replace from '@rollup/plugin-replace';
    import json from '@rollup/plugin-json'
    ...
    plugins: [
            replace({
                __api: JSON.stringify({
                    env: {
                        ...config().parsed // attached the .env config
                    }
                }),
            }),
            json(),
            svelte({
                compilerOptions: {
                    // enable run-time checks when not in production
                    dev: !production
                }
            }),
            ...
    .env and supabaseClient.js is the same as that guide. This is the error I face:
    Copy code
    supabaseClient.js:10 Uncaught ReferenceError: __api is not defined
  • c

    cataxcab

    09/03/2021, 11:31 AM
    I'm guessing I'm doing something wrong with rollup.config.js, not able to find what that is :/
  • e

    EmreCan

    09/03/2021, 11:49 AM
    hello i need help urgent inside a middleware i cannot get supabase.auth.user() value
  • e

    EmreCan

    09/03/2021, 11:49 AM
    I am using nuxt
  • e

    EmreCan

    09/03/2021, 11:49 AM
    auth.api.getUserByCookie() when i use this
1...717273...316Latest