proper register nav menu with 2 arguments called in a function