adding the function registration decorator