updated function spec