错误的Grails 2.0.0.RC3上的贝宝插件 [英] Error PayPal plugin on grails 2.0.0.RC3
问题描述
错误编译错误:启动失败:
/Users/sartre/.grails/2.0.0.M1/projects/testapp/plugins/paypal-0.6.4/grails-app/controllers/org/grails/paypal/PaypalController.groovy: - 1:org.grails.paypal.PaypalController中的java.lang.Object notify()的返回类型与java.lang.Object
中的void notify()不兼容。在[-1:-1] @行-1,列-1。
1错误
我该如何解决它?
非常感谢任何想法
grails 2.0中的不兼容性改变!
它似乎与grails 2.0中的一个小改动有关。
现在可以将控制器操作定义为方法而不像以前版本的Grails那样使用闭包。 (来自官方文档: http://grails.org/doc/2.0。
它的行为与PayPalController中的闭包通知相同,它将覆盖Object.notify方法。
如果您在notifyPaypal中重命名notify,它应该可以正常工作。
I use grails 2.0.0.rc3, when I install PayPal plugin I have this error:
Error Compilation error: startup failed:
/Users/sartre/.grails/2.0.0.M1/projects/testapp/plugins/paypal-0.6.4/grails-app/controllers/org/grails/paypal/PaypalController.groovy: -1: The return type of java.lang.Object notify() in org.grails.paypal.PaypalController is incompatible with void notify() in java.lang.Object
. At [-1:-1] @ line -1, column -1.
1 error
How can I fix it?
Many thanks for any idea
Incompatibility change in grails 2.0!! It seems that it is related to a small change in grails 2.0.
It is now possible to define controller actions as methods instead of using closures as in previous versions of Grails. (from official doc : http://grails.org/doc/2.0.x/guide/introduction.html#webFeatures)
It behaves like the closure notify in PaypalController overrides the Object.notify method. If you rename notify in notifyPaypal, it should work.
这篇关于错误的Grails 2.0.0.RC3上的贝宝插件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!