Skip to content
This repository has been archived by the owner on Jul 27, 2023. It is now read-only.

Commit

Permalink
[fix] server smtp
Browse files Browse the repository at this point in the history
  • Loading branch information
albancrommer committed Jun 21, 2014
1 parent c9f11cf commit e0e720c
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions server/main.js
@@ -1,16 +1,21 @@
// In your server code: define a method that the client can call
Meteor.methods({
sendEmail: function (from, to, subject, text) {
check([from, to, subject, text], [String]);
check([from, subject, text], [String]);

// Let other method calls from the same client start running,
// without waiting for the email sending to complete.
// this.unblock();
Email.send({
to: to,
to: "admin@nsa-observer.net",
from: from,
subject: subject,
text: text
});
}
});
// Sets the environnement function
Meteor.startup(function () {
process.env.MAIL_URL = "smtp://localhost"
});

0 comments on commit e0e720c

Please sign in to comment.