質問するログイン新規登録

質問編集履歴

1

nginxのログについて追加があったので加えました。

2019/10/15 06:39

投稿

Otazoman
Otazoman

スコア44

title CHANGED
@@ -1,1 +1,1 @@
1
- StaticPressで指定ディレクトリを除外して出力したい。
1
+ StaticPressで指定ディレクトリを除外して出力しようとするとエラーになる
body CHANGED
@@ -21,7 +21,15 @@
21
21
 
22
22
  nginxのログを確認すると以下のような出力がありました。
23
23
  ```
24
- 2019/10/12 18:42:41 [error] 1443#1443: *7093 FastCGI sent in stderr: "PHP message: PHP Fatal error: Uncaught ArgumentCountError: Too few arguments to function static_rm(), 1 passed in /var/www/hoge/wp-includes/class-wp-hook.php on line 288 and exactly 2 expected in /var/www/hoge/wp-content/plugins/staticpress/plugin.php:61
24
+ 2019/10/15 13:51:45 [error] 1490#1490: *557 FastCGI sent in stderr: "PHP message: PHP Fatal error: Uncaught ArgumentCountError: Too few arguments to function replace_url_of_feed(), 1 passed in /var/www/hoge/wp-includes/class-wp-hook.php on line 288 and exactly 2 expected in /var/www/hoge/wp-content/plugins/staticpress/plugin.php:72
25
+ Stack trace:
26
+ #0 /var/www/hoge/wp-includes/class-wp-hook.php(288): replace_url_of_feed('/var/www/hoge...')
27
+ #1 /var/www/hoge/wp-includes/class-wp-hook.php(310): WP_Hook->apply_filters('', Array)
28
+ #2 /var/www/hoge/wp-includes/plugin.php(465): WP_Hook->do_action(Array)
29
+ #3 /var/www/hoge/wp-content/plugins/staticpress/includes/class-static_press.php(415): do_action('StaticPress::fi...', '/var/www/hoge...', 'https://cms.hog...')
30
+ #4 /var/www/hoge/wp-content/plugins/staticpress/includes/class-static_press.php(179): static_press->create_static_file('/chikaramochi.h...', 'single', true, true)
31
+ #5 /var/www/hoge/wp-includes/class-wp-hook.php(286): static_press->ajax_fetch('')
32
+ #6 /var/www/hoge/wp-include" while reading response header from upstream, client: XXX.XX.XXX.XX, server: XX.XXX.XXX.XX, request: "POST /wp-admin/admin-ajax.php HTTP/1.1", upstream: "fastcgi://unix:/var/run/php/php7.3-fpm.sock:", host: "cms.hoge.com", referrer: "https://cms.hoge.com/wp-admin/admin.php?page=static-press"
25
33
  ```
26
34
 
27
35
  ### 該当のソースコード