lookback / meteor-emails

Improved Meteor emails with templating, previews and automated CSS/SCSS inlining.

Home Page:https://atmospherejs.com/lookback/emails

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Getting error on init after upgrade to 0.7.2

adamgins opened this issue · comments

image

Here's my init:

 Mailer.init({
        templates: Templates,     // Global Templates namespace, see lib/templates.js.
        helpers: TemplateHelpers, // Global template helper namespace.
        layout: {
            name: 'emailLayout',
            path: 'emails/email-notification/layout.html',   // Relative to 'private' dir.
            scss: 'emails/email-notification/style.scss'
        }
    });

it looks right... did anything change?

Thanks for the quick reply.

No. Here's my file:

Templates = {};

Templates.commentNotification = {
  path: 'emails/email-notification/comment.html',    // Relative to the 'private' dir.
  scss: 'emails/email-notification/style.scss',      // Mail specific SCSS.

  helpers: {
    capitalizedName: function() {
      return this.name.charAt(0).toUpperCase() + this.name.slice(1);
    }
  }
};
Templates.resourceNotification = {
  path: 'emails/email-notification/resource.html',    // Relative to the 'private' dir.
  scss: 'emails/email-notification/style.scss',       // Mail specific SCSS.

  helpers: {
    capitalizedName: function() {
      return this.name.charAt(0).toUpperCase() + this.name.slice(1);
    }
  }
};
Templates.inviteEmail = {
  path: 'emails/email-notification/invite.html',      // Relative to the 'private' dir.
  scss: 'emails/email-notification/style.scss',       // Mail specific SCSS.

  helpers: {
    capitalizedName: function() {
      return this.name.charAt(0).toUpperCase() + this.name.slice(1);
    }
  }
};
Templates.activationEmail = {
  path: 'emails/email-notification/activate.html',    // Relative to the 'private' dir.
  scss: 'emails/email-notification/style.scss',       // Mail specific SCSS.

  helpers: {
    capitalizedName: function() {
      return this.name.charAt(0).toUpperCase() + this.name.slice(1);
    }
  }
};

Ah cool.. I had addRoutes:true now set to addRoutes:false .. thanks .. phew I have had that param there for ages. ... you must have fixed something that made my slackness break it ;-)

Heh, okay :) I addressed this anyway in c22ba33 – instead of crashing, it'll log and exit.

Thanks