Fix docroot and argument order in method_exists.