Year Drop Down Error

Hello,
I am currently building date of birth functionality in Appgyver and am having trouble with the year drop down. I may have over complicated things.

  1. I have created two page variables. One called “current_year” which is a number and the other page variable “years” which is a list of numbers.

  1. On page mounted I set the page variable current_year using the formula - GET_DATETIME_COMPONENT(NOW(), “year”)

  2. After that I set another page variable “years” by using the following formula - GENERATE_RANGE(1990, pageVars.current_year, 1). This essentially generates a range for the drop down list.

image

  1. I then use a MAP formula for my option list which is - MAP(pageVars.years, {label: item, value: item}). While it says the list items are incompatible it still shows my years in the drop down list nicely.

image

However, when I go to select a value the app crashes with the following error below. I have created another page variable called “customer_year_of_birth” which is used as a page variable for the selected value. I had a feeling this could have been because of incompatible data types but the error crashing the app doesn’t seem to indicate that. Any help would be appreciated. Thank you.

Type Error: TypeError: n.filter is not a function. (In ‘n.filter(function(t){return t.label})’, ‘n.filter’ is undefined)

This error is located at:

in Component

in Unknown

in A

in RCTView

in M

in Unknown

in A

in RCTView

in M

in Unknown

in A

in RCTView

in M

in Unknown

in A

in RCTView

in M

in Unknown

in A

in RCTScrollContentView

in RCTScrollView

in z

in KeyboardAwarez

in Component

in Unknown

in A

in RCTView

in c

in y

in A

in Unknown

in Unknown

in Unknown

in Unknown

in RCTView

in RCTView

in RCTView

in ForwardRef

in RCTView

in P

in PanGestureHandler

in Unknown

in RCTView

in P

in RCTView

in G

in Unknown

in RCTView

in Unknown

in RCTView

in Unknown

in R

in h

in Unknown

in RCTView

in w

in Unknown

in Unknown

in O

in A

in ForwardRef

in Unknown

in Unknown

in Unknown

in Unknown

in RCTView

in RCTView

in RCTView

in ForwardRef

in RCTView

in P

in PanGestureHandler

in Unknown

in RCTView

in P

in RCTView

in G

in Unknown

in RCTView

in Unknown

in RCTView

in Unknown

in R

in h

in RNCSafeAreaProvider

in Unknown

in Unknown

in RCTView

in w

in Unknown

in q

in RCTView

in Unknown

in ForwardRef

in Unknown

in ForwardRef

in Unknown

in A

in c

in c

in K

in RCTView

in Unknown

in k

in Root

in RCTView

in x

Potentially was an actual bug with AppGyver. Looks to be fixed now on web and mobile.