平台开发中,欢迎参与测试。你可以在 QQ群:1046115671 中与我们交流,或是直接在社区发帖

    cravatar.cn 上传头像失败

    • iMaeGooiMaeGoo
      楼主
      iMaeGooiMaeGoo
      楼主
      iMaeGoo
      楼主

      观察控制台 network 发现有 API 报了 500 错误

      API:https://cravatar.cn/wp-admin/admin-ajax.php
      报错:

      <b>Fatal error</b>: Uncaught Error: Cannot use object of type WP_Error as array in /www/wwwroot/litepress.cn/wp-content/themes/cravatar/inc/class-upyun.php:36
      Stack trace:
      #0 /www/wwwroot/litepress.cn/wp-content/themes/cravatar/inc/class-upyun.php(40): LitePress\Cravatar\Inc\Upyun->send_request()
      #1 /www/wwwroot/litepress.cn/wp-content/themes/cravatar/inc/helpers.php(424): LitePress\Cravatar\Inc\Upyun->post()
      #2 /www/wwwroot/litepress.cn/wp-content/themes/cravatar/functions.php(60): LitePress\Cravatar\Inc\purge_avatar_cache()
      #3 /www/wwwroot/litepress.cn/wp-includes/class-wp-hook.php(303): {closure}()
      #4 /www/wwwroot/litepress.cn/wp-includes/class-wp-hook.php(327): WP_Hook->apply_filters()
      #5 /www/wwwroot/litepress.cn/wp-includes/plugin.php(470): WP_Hook->do_action()
      #6 /www/wwwroot/litepress.cn/wp-content/plugins/ultimate-member/includes/core/class-uploader.php(493): do_action()
      #7 /www/wwwroot/litepress.cn/wp-content/plugins/ultimate-member/includes/core/class-files.php(412): um\core\Uploader->upload_image()
      #8 /www/wwwroot/litepress.cn/wp-includes/class-wp-hook.php(303): um\core\Files->ajax_image_upload()
      #9 /www/wwwroot/litepress.cn/wp-includes/class-wp-hook.php(327): WP_Hook->apply_filters()
      #10 /www/wwwroot/litepress.cn/wp-includes/plugin.php(470): WP_Hook->do_action()
      #11 /www/wwwroot/litepress.cn/wp-admin/admin-ajax.php(187): do_action()
      #12 {main}
      thrown in <b>/www/wwwroot/litepress.cn/wp-content/themes/cravatar/inc/class-upyun.php</b> on line <b>36</b>

      此站点遇到了致命错误。

      了解有关对 LitePress 进行故障排除的更多信息。

      标签: 

      #22131
  • iMaeGooiMaeGoo
    楼主
    iMaeGooiMaeGoo
    楼主
    iMaeGoo
    楼主

    问题的主体:cravatar

    问题的网址:https://cravatar.cn/emails

    问题的复现:上传一个头像并调整预览框大小

  • 正在查看 1 条回复
    • 哎呀,回复话题必需登录。

    加入 LitePress 论坛 ,参与知识分享与交流
    登录 注册 进行评论
    立即加入