Error with brmsformula

Hi, I am new to R and stan.
I have this script below for brms formula, however I keep receiving an error

formula <- brmsformula(act_effort ~ acap + pcap + cplx + year, data = df)

Error: Expecting a single value when fixing parameter ‘data.year’.

my dataset columns are of type num. Actual values are double values.

changing year to num does not help.

You shouldn’t pass a data argument inside the brms::brmsformula function. Your data should be passed to the data argument of brms::brm.