-
Notifications
You must be signed in to change notification settings - Fork 9
Description
Hello
I am trying to send an email using the template store in the database. The email is being send successfully but in email I am getting following error:
Liquid error: internal
The content in database record is <div>{{ user.name }}</div>.
Following is my mailer:
class UserMailer < ApplicationMailer
prepend_view_path TemplateStorage.resolverdef welcome(user)
@user = user.attributes
@stored_template = TemlateStorage.where(template_name: "welcome_user").last
mail(to: user.email, subject: "Welcome to our website")
end
end
Following is the content of my model:
require 'liquid_markdown/resolver' # required
class TemplateStorage < ApplicationRecord
attribute :handler, :string, default: 'liqmd'
attribute :format, :string, default: 'html'
attribute :path, :string, default: '/'
store_templates
def self.resolver(options={})
LiquidMarkdown::Resolver.using self, options
end
end
Following is the error that I am getting:
I am not sure where am I going wrong with the steps mentioned in the Readme file.
