Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save steventux/769c59bf432010ced065 to your computer and use it in GitHub Desktop.
Save steventux/769c59bf432010ced065 to your computer and use it in GitHub Desktop.
DraftContentItem.where(publishing_app: "email-campaign-frontend").each do |content_item|
content_item.update_attributes!(publishing_app: "share-sale-publisher")
payload = Presenters::ContentStorePresenter.present(content_item)
ContentStoreWorker.perform_async(
content_store: Adapters::DraftContentStore,
base_path: content_item.base_path,
payload: payload,
)
end
LiveContentItem.where(publishing_app: "email-campaign-frontend").each do |content_item|
content_item.update_attributes!(publishing_app: "share-sale-publisher")
payload = Presenters::ContentStorePresenter.present(content_item)
ContentStoreWorker.perform_async(
content_store: Adapters::ContentStore,
base_path: content_item.base_path,
payload: payload,
)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment