merged positional and named into one function