Move acts_as_publishable from plugin to lib to support Rails 4.0+