@@ -9,6 +9,7 @@ import { FastifyPluginAsync } from "fastify";
99import {
1010 BaseError ,
1111 InternalServerError ,
12+ NotImplementedError ,
1213 ValidationError ,
1314} from "common/errors/index.js" ;
1415import { getEntraIdToken } from "api/functions/entraId.js" ;
@@ -23,6 +24,7 @@ import stripe, { Stripe } from "stripe";
2324import { AvailableSQSFunctions , SQSPayload } from "common/types/sqsMessage.js" ;
2425import { SendMessageCommand , SQSClient } from "@aws-sdk/client-sqs" ;
2526import rawbody , { RawBodyPluginOptions } from "fastify-raw-body" ;
27+ import { ListModificationPatchRequest } from "common/types/membership.js" ;
2628
2729const NONMEMBER_CACHE_SECONDS = 1800 ; // 30 minutes
2830const MEMBER_CACHE_SECONDS = 43200 ; // 12 hours
@@ -73,7 +75,7 @@ const membershipPlugin: FastifyPluginAsync = async (fastify, _options) => {
7375 Body : undefined ;
7476 Params : { netId : string } ;
7577 } > ( "/checkout/:netId" , async ( request , reply ) => {
76- const netId = request . params . netId ;
78+ const netId = request . params . netId . toLowerCase ( ) ;
7779 if ( ! validateNetId ( netId ) ) {
7880 throw new ValidationError ( {
7981 message : `${ netId } is not a valid Illinois NetID!` ,
@@ -147,7 +149,7 @@ const membershipPlugin: FastifyPluginAsync = async (fastify, _options) => {
147149 Querystring : { list ?: string } ;
148150 Params : { netId : string } ;
149151 } > ( "/:netId" , async ( request , reply ) => {
150- const netId = request . params . netId ;
152+ const netId = request . params . netId . toLowerCase ( ) ;
151153 const list = request . query . list || "acmpaid" ;
152154 if ( ! validateNetId ( netId ) ) {
153155 throw new ValidationError ( {
0 commit comments