/** * Returns the custom code snippet file path. * * @since 1.0.0 * * @return string The file path to the custom snippets file */ public static function get_snippets_file_path() { $uploads_dir = wp_upload_dir(); $snippets_dir = explode('/', plugin_basename(__FILE__)); return self::$snippets_file = trailingslashit($uploads_dir['basedir']) . trailingslashit($snippets_dir[0]) . 'custom.php'; }