OndrejKunc / flutter_dynamic_forms

A collection of flutter and dart libraries allowing you to consume complex external forms at runtime.
MIT License
204 stars 60 forks source link

expressions.dart - support zero parameters. #109

Open philsnook opened 2 years ago

philsnook commented 2 years ago

In order to implement a function such as LEN... which checks the length of a string.

Please add the following check to isNumber under expressions.dart

This allows zero an empty string to be evaluated as false.

Ref: Line 334

bool isNumber(String st) {
    if (st.isEmpty) {
      return false;
    }
.....