@@ -111,7 +111,7 @@ private function register_hooks() {
111
111
add_action ( 'wp_enqueue_scripts ' , array ( $ this , 'enqueue_scripts ' ) );
112
112
add_action ( 'template_redirect ' , array ( $ this , 'load_theme ' ) );
113
113
add_action ( 'customize_loaded_components ' , array ( $ this , 'ensure_widget_editing ' ) );
114
- add_action ( 'friends_activate_theme_default ' , array ( $ this , 'default_theme ' ) );
114
+ add_action ( 'friends_load_theme_default ' , array ( $ this , 'default_theme ' ) );
115
115
add_action ( 'friends_template_paths ' , array ( $ this , 'friends_template_paths ' ) );
116
116
add_action ( 'wp_enqueue_scripts ' , array ( $ this , 'dequeue_scripts ' ), 99999 );
117
117
add_action ( 'wp_footer ' , array ( $ this , 'dequeue_scripts ' ) );
@@ -253,17 +253,17 @@ public function load_theme() {
253
253
$ theme = $ post_type_theme ;
254
254
}
255
255
}
256
- if ( ! has_action ( 'friends_activate_theme_ ' . $ theme ) ) {
256
+ if ( ! has_action ( 'friends_load_theme_ ' . $ theme ) ) {
257
257
$ theme = 'default ' ;
258
258
}
259
259
$ this ->theme = $ theme ;
260
- do_action ( 'friends_activate_theme_ ' . $ theme );
260
+ do_action ( 'friends_load_theme_ ' . $ theme );
261
261
}
262
262
263
263
public function friends_template_paths ( $ file_paths ) {
264
264
$ backup_file_paths = $ file_paths ;
265
- if ( has_filter ( 'friends_theme_template_paths_ ' . $ this ->theme ) ) {
266
- $ file_paths = apply_filters ( 'friends_theme_template_paths_ ' . $ this ->theme , $ file_paths );
265
+ if ( has_filter ( 'friends_template_paths_theme_ ' . $ this ->theme ) ) {
266
+ $ file_paths = apply_filters ( 'friends_template_paths_theme_ ' . $ this ->theme , $ file_paths );
267
267
}
268
268
if ( empty ( $ file_paths ) ) {
269
269
return $ backup_file_paths ;
0 commit comments