Skip to content

no implicit conversion of Pathname into String #758

Closed
@eni9889

Description

@eni9889

Describe your problem here.

Commands

bundle exec rake annotate_models

example model below. Also, primary keys are uuid in case that matters

class Site < ApplicationRecord
  belongs_to :user
  validates :anchor_link, url: { allow_blank: true, allow_nil: true }

  after_create_commit :post_creation_callback

  def post_creation_callback
    Seo::ChooseAnchorTextJob.perform_later(self.class.to_s, id)
  end

  after_save do
    if saved_change_to_anchor_text? || saved_change_to_anchor_link?
      Seo::SyncAnchorTextJob.set(wait: 1.minutes).perform_later(self.class.to_s, self.id) rescue nil
    end
  end
end

Version

  • annotate version: 3.0.3
  • rails version: 5.2.3
  • ruby version: 2.5.1p57

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions