The Error “Fatal error: Uncaught ReflectionException: Method get_site_editor_type does not exist”, is an error that is seen when you are working on WordPress and trying to use the site after a long of inactivity from your side.
The error is usually seen when you are trying to use the log-in feature in your site.
Given below is the snippet of the error you might get:
Fatal error: Uncaught ReflectionException: Method get_site_editor_type does not exist
The error, “Fatal error: Uncaught ReflectionException: Method get_site_editor_type does not exist” is usually seen because of a bug form the developers side in the recent WordPress update.
This is an error from the WordPress developers side, there is nothing much we can do except to wait for the official fix release. Until then some temporary workarounds can help you to bypass the error.
To fix the error, find the line code which states: “wp-content/plugins/elementor-pro/modules/theme-builder/documents/theme-document.php“, comment it out and save back and error would be fixed.
Change the line of code $method = $reflection->getMethod( ‘get_site_editor_type’ ); with //$method = $reflection->getMethod( ‘get_site_editor_type’ ); in your project file and error ‘Fatal error: Uncaught ReflectionException: Method get_site_editor_type does not exist’ would be fixed.
Steps to fix the error “Fatal error: Uncaught ReflectionException: Method get_site_editor_type does not exist” is mentioned below:
Step 1: Comment Out Theme Document File
First you will have to find the following mentioned line of code in your project file; “/wp-content/plugins/elementor-pro/modules/theme-builder/documents/theme-document.php“.
Once you have found the above mentioned line of code in your project file, you will have to comment it out in you project file.
Step 2: Change the ‘get_site_editor_type’ Code Line
Then you will have to change the below mentioned line of code:
$method = $reflection->getMethod( 'get_site_editor_type' );
You will have to change the above to:
//$method = $reflection->getMethod( 'get_site_editor_type' );
This should help you fix the error, “Fatal error: Uncaught ReflectionException: Method get_site_editor_type does not exist”.
Conclusion
To fix the error, “Fatal error: Uncaught ReflectionException: Method get_site_editor_type does not exist”, in your line of code you will have to find the line code which says; “wp-content/plugins/elementor-pro/modules/theme-builder/documents/theme-document.php” and then you will have to comment it out.
You will also have to change a line of ode in your project to file to a line of code which does not throw an error.