Skip to content

2.4.0

Compare
Choose a tag to compare
@jan-tennert jan-tennert released this 09 May 17:41
· 556 commits to master since this release
bca7989

Changes

Core

Auth

  • Auth changes & fixes by @jan-tennert in #568
    • The method Auth#linkIdentity will now return the OAuth URL if the config value ExternalAuthConfigDefaults.automaticallyOpenUrl is set to false.
      Otherwise, null.
    • Fix the autoRefresh default value for Auth#importSession not being set to config.alwaysAutoRefresh
    • Add codeVerifier parameter to MemoryCodeVerifierCache to be able to set an initial value
    • Add missing captchaToken config option in the OTP auth provider
  • Change the default session key for the SettingsSessionManager to work with multiple instances on the same device and add a key parameter to the constructor in case you want a custom key by @MohamedRejeb in #572

Realtime

  • Add new experimental extension functions to retrieve initial data and listen for updates without using realtime channels by @jan-tennert #579:
//Not a suspending function, subscribing and unsubscribing is handled internally
val myProductFlow: Flow<Product> = supabase.from("products").selectSingleValueAsFlow(Product::id) {
    Product::id eq 2
}.collect {
    println(it)
}
val productsFlow: Flow<List<Product>> = supabase.from("products").selectAsFlow(Product::id, filter = FilterOperation("id", FilterOperator.GT, 2)).collect {
    println(it)
}

This requires both Realtime and Postgrest to be installed within the SupabaseClient.

Storage

  • Prohibit uploading empty data to a bucket by @hieuwu in #577

Functions

  • Add new region parameter to invoke functions which allows changing the region where the Edge Function will be invoked in. Defaults to Functions.Config#defaultRegion (which is FunctionRegion.ANY) by @jan-tennert in #580