我正在使用
private_pub将订阅客户端的通知推送给我的用户.在我的application.html.haml中,我有:
... = javascript_include_tag 'application' = subscribe_to "/#{@user.access_token}/notifications" ...
subscribe_to帮助程序在开发中工作正常.部署到生产时,会记录以下错误:
ActionView::Template::Error (undefined method `subscribe_to' for #<#<Class:0x00000001f372e8>:0x00000001fded90>): 5: = stylesheet_link_tag 'application',:media => 'all' 6: = include_gon(:init => true) 7: = javascript_include_tag 'application' 8: = subscribe_to "/#{@user.access_token}/notifications" 9: = csrf_Meta_tags 10: 11: %body app/views/layouts/application.html.haml:8:in `_app_views_layouts_application_html_haml__1867651381877570337_14592040'
如何在生产环境中访问此帮助程序方法?