fix wrong number of arguments (3 for 2) in factory