Fixes registerMethod to pass test