public function post_template_routing($template_path)
    {
        $routes_file = \get_template_directory() . '/public/routes.php';
        
        if (\is_child_theme()) {
            $routes_file = \locate_template('public/routes.php');
        }

        if ('' !== $routes_file) {
            return $routes_file;
        }
        
        return $template_path;
    }
public function post_template_routing($template_path)
    {
        $routes_file = \get_template_directory() . '/public/routes.php';
        
        if (\is_child_theme()) {
            $routes_file = \locate_template('public/routes.php');
        }

        if ('' !== $routes_file) {
            return $routes_file;
        }
        
        return $template_path;
    }
public function post_template_routing ( $ template_path ) { $ routes_file = \ get_template_directory ( ) . '/public/routes.php' ; if ( \ is_child_theme ( ) ) { $ routes_file = \ locate_template ( 'public/routes.php' ) ; } if ( '' !== $ routes_file ) { return $ routes_file ; } return $ template_path ; }
Ensure post template requests get routed to our main front controller instead of some random file.

@since  1.0.0

@param  string $template_path Path of template to load.
@return string Path of template to load.
Ensure post template requests get routed to our main front controller instead of some random file .