Skip to content

Not possible to pass Null constant to nullable properties #252

@isegal

Description

@isegal

Expected behavior (required)

When defining nullable properties in custom components, custom functions or custom actions, it is impossible to pass Null constant from FF to the properties:

image

image

Since it's impossible to explicitly pass the Null constant, leaving a nullable parameter undefined makes FF report it as an error.

Current behavior (required)

Null appears in red, so it is not possible to pass it.

Workaround:
We have to create a custom function that returns a specific nullable type for each data type and return null from that function. We then have to pass that function as parameter.

To Reproduce (required)

Steps to reproduce the behavior:

  1. Create a custom function or component that takes a nullable Document type parameter
  2. Add the component to a page
  3. For parameter, select Specific Variable -> Constant -> Null

Bug Report Code

Context (required)

Need to be able to pass Nulls in some cases when it makes sense (eg a value does not exist).

Screenshots / recordings

Your environment

  • Version of FlutterFlow used: 1.1.27
  • Platform (e.g. Web, MacOS Desktop): MacOS Desktop
  • Browser name and version: N/A
  • Operating system and version (desktop or mobile): OSX Ventura 13.0.1

Metadata

Metadata

Labels

status: needs triageA potential issue that has not been confirmed as a bug.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions