如何摆脱此插件的class_inheritable_attribute弃用警告? [英] how to get rid of this plugin's class_inheritable_attribute deprecation warning?

查看:99
本文介绍了如何摆脱此插件的class_inheritable_attribute弃用警告?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我收到有关正在使用的插件的警告:

I'm getting this warning for a plugin I'm using:

 DEPRECATION WARNING: class_inheritable_attribute is deprecated, please use class_attribute method instead. Notice their behavior are slightly different, so refer to class_attribute documentation first. (called from has_private_messages at /vendor/plugins/simple-private-messages/lib/has_private_messages_extensions.rb:17)

我在 https://github.com/jongilbraith/simple-private创建了一个问题-消息,但最近没有太多活动.

I've created an issue at https://github.com/jongilbraith/simple-private-messages, but there isn't much recent activity on it.

我不熟悉class_inheritable_attribute ...不知道如何自己打补丁.有提示吗?

I'm not familiar with class_inheritable_attribute... don't know how to patch this myself. Any hints?

推荐答案

在GitHub上分叉插件,找到对class_inheritable_attribute的调用并将其更改为class_attribute.从您的vendor/plugins目录中删除旧插件,然后添加新插件.那将删除过时警告.

Fork the plugin on GitHub and find the calls to class_inheritable_attribute and change them to class_attribute. Remove the old plugin from your vendor/plugins directory and add the new one. That would remove the deprecation warning.

这篇关于如何摆脱此插件的class_inheritable_attribute弃用警告?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆