Added web and email notifications. Tests. Fire page
This commit is contained in:
parent
df05b33e82
commit
3bf21c8caf
32 changed files with 696 additions and 88 deletions
22
imports/api/Fires/methods.js
Normal file
22
imports/api/Fires/methods.js
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
/* eslint-disable import/no-absolute-path */
|
||||
|
||||
import { Meteor } from 'meteor/meteor';
|
||||
import { check } from 'meteor/check';
|
||||
import rateLimit from '/imports/modules/rate-limit';
|
||||
import urlEnc from '/imports/modules/url-encode';
|
||||
|
||||
Meteor.methods({
|
||||
'fire.decrypt': async function fireDecode(fireEnc) {
|
||||
check(fireEnc, String);
|
||||
const unsealed = await urlEnc.decrypt(fireEnc);
|
||||
return unsealed;
|
||||
}
|
||||
});
|
||||
|
||||
rateLimit({
|
||||
methods: [
|
||||
'fire.decode'
|
||||
],
|
||||
limit: 5,
|
||||
timeRange: 1000
|
||||
});
|
||||
Loading…
Add table
Add a link
Reference in a new issue