Compare commits
No commits in common. "e5173679673c67cbc033af890b2d1fc29a89786a" and "3f3b42e2ec625d67d0e5f4d48780fe64e95b7a06" have entirely different histories.
e517367967
...
3f3b42e2ec
@ -1,9 +1,6 @@
|
|||||||
import { onRequest } from "firebase-functions/v2/https";
|
import { onRequest } from "firebase-functions/v2/https";
|
||||||
import { getCorsHandler } from "../shared/middleware";
|
import { getCorsHandler } from "../shared/middleware";
|
||||||
import { getAdmin, getLogger } from "../shared/config";
|
import { getAdmin, getLogger } from "../shared/config";
|
||||||
import { Request } from "firebase-functions/v2/https";
|
|
||||||
import { Response } from "express";
|
|
||||||
|
|
||||||
|
|
||||||
const corsHandler = getCorsHandler();
|
const corsHandler = getCorsHandler();
|
||||||
const admin = getAdmin();
|
const admin = getAdmin();
|
||||||
@ -11,7 +8,7 @@ const logger = getLogger();
|
|||||||
|
|
||||||
export const registerClient = onRequest({
|
export const registerClient = onRequest({
|
||||||
region: '#{SERVICES_RGN}#'
|
region: '#{SERVICES_RGN}#'
|
||||||
}, async (req: Request, res: Response) => {
|
}, async (req, res) => {
|
||||||
return corsHandler(req, res, async () => {
|
return corsHandler(req, res, async () => {
|
||||||
try {
|
try {
|
||||||
if (req.method !== 'POST') {
|
if (req.method !== 'POST') {
|
||||||
@ -2,7 +2,6 @@ import { getLogger } from "../shared/config";
|
|||||||
import { getCorsHandler } from "../shared/middleware";
|
import { getCorsHandler } from "../shared/middleware";
|
||||||
import { onRequest } from "firebase-functions/v2/https";
|
import { onRequest } from "firebase-functions/v2/https";
|
||||||
import { Request } from "firebase-functions/v2/https";
|
import { Request } from "firebase-functions/v2/https";
|
||||||
import { Response } from "express";
|
|
||||||
import { SESClient } from "@aws-sdk/client-ses";
|
import { SESClient } from "@aws-sdk/client-ses";
|
||||||
import { SendEmailCommand, SendRawEmailCommand } from "@aws-sdk/client-ses";
|
import { SendEmailCommand, SendRawEmailCommand } from "@aws-sdk/client-ses";
|
||||||
import { HttpsError } from "firebase-functions/v2/https";
|
import { HttpsError } from "firebase-functions/v2/https";
|
||||||
@ -137,7 +136,7 @@ async function downloadFileFromUrl(url: string): Promise<Buffer> {
|
|||||||
|
|
||||||
export const sendEmailSES = onRequest({
|
export const sendEmailSES = onRequest({
|
||||||
region: 'asia-south1'
|
region: 'asia-south1'
|
||||||
}, (request: Request, response: Response) => {
|
}, (request: Request, response) => {
|
||||||
return corsHandler(request, response, async () => {
|
return corsHandler(request, response, async () => {
|
||||||
try {
|
try {
|
||||||
const toAddress = request.body.toAddress;
|
const toAddress = request.body.toAddress;
|
||||||
|
|||||||
@ -16,4 +16,4 @@ export { accessFile } from './storage';
|
|||||||
export { processNotificationOnCreate } from './notifications';
|
export { processNotificationOnCreate } from './notifications';
|
||||||
export * from './payments';
|
export * from './payments';
|
||||||
export { getPlaceDetails, getPlacesAutocomplete } from './places';
|
export { getPlaceDetails, getPlacesAutocomplete } from './places';
|
||||||
export { registerClient } from './users';
|
export { registerClient } from './clientRegistration';
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user