Skip to content

Commit

Permalink
🔥 Eliminate code to swith of dialogflow
Browse files Browse the repository at this point in the history
  • Loading branch information
ChristianJoe committed May 5, 2021
1 parent 63158dc commit bfc9190
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions entrypoint/fb.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import handler from '../handler';
import Raven from 'raven';
import RavenLambdaWrapper from 'serverless-sentry-lib';
import { contact, feedbackMode, contactWithLink } from '../handler/actionContact';
import moment from 'moment';


export const verify = RavenLambdaWrapper.handler(Raven, (event, context, callback) => {
Expand Down Expand Up @@ -104,20 +103,6 @@ const handleMessage = async (event, context, chat, msgEvent) => {
return;
}

// disable bot partially on wednesday, 05.May 2021
// Will be reverted after 05.05.2021
if ( moment('2021-05-05T11:00:00+02:00') < moment.now() &&
moment.now() < moment('2021-05-05T13:00:00+02:00') ) {
return;
}

// disable bot partially on wednesday, 04.May 2021 to Test-Feature
// Production push will be after 2021-05-04T1T12:00:00+02:00
if ( moment('2021-05-04T11:45:00+02:00') < moment.now() &&
moment.now() < moment('2021-05-04T12:00:00+02:00') ) {
return;
}

let text = '#dontknowwhatthisis';
if ('text' in msgEvent.message) {
text = msgEvent.message.text;
Expand Down

0 comments on commit bfc9190

Please sign in to comment.