diff --git a/CHANGELOG.md b/CHANGELOG.md index 0572f78013..d66fc5f5c1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,12 +4,39 @@ All notable changes to this project will be documented in this file. Dates are d Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog). +#### [v6.89.1](https://github.com/opengovsg/FormSG/compare/v6.89.0...v6.89.1) + +- build: release v6.89.0 [`#6898`](https://github.com/opengovsg/FormSG/pull/6898) +- fix: remove myinfo child from storage mode [`#6901`](https://github.com/opengovsg/FormSG/pull/6901) +- fix: add error handling [`d6c4985`](https://github.com/opengovsg/FormSG/commit/d6c4985aa8e35dd2278af9b70d00d4e86a48bde1) +- fix: remove email mode from myinfo limit message [`5a45c98`](https://github.com/opengovsg/FormSG/commit/5a45c980dbe3fc8c15eacb3ff1827f3003fcbfc4) + +#### [v6.89.0](https://github.com/opengovsg/FormSG/compare/v6.88.0...v6.89.0) + +> 15 November 2023 + +- fix: add learn more link [`#6897`](https://github.com/opengovsg/FormSG/pull/6897) +- chore: security upgrade axios to 1.6.2 [`#6893`](https://github.com/opengovsg/FormSG/pull/6893) +- feat: myinfo for storage-mode [`#6870`](https://github.com/opengovsg/FormSG/pull/6870) +- feat: announcement modal and what's new for myinfo storage-mode [`#6892`](https://github.com/opengovsg/FormSG/pull/6892) +- chore: remove eb shift frontend feature flags [`#6869`](https://github.com/opengovsg/FormSG/pull/6869) +- chore(deps-dev): bump @types/lodash from 4.14.200 to 4.14.201 in /shared [`#6888`](https://github.com/opengovsg/FormSG/pull/6888) +- chore(deps): bump axios from 1.2.1 to 1.6.0 in /frontend [`#6887`](https://github.com/opengovsg/FormSG/pull/6887) +- fix(deps): bump axios from 1.2.1 to 1.6.0 [`#6886`](https://github.com/opengovsg/FormSG/pull/6886) +- fix(deps): bump type-fest from 4.5.0 to 4.7.1 in /shared [`#6883`](https://github.com/opengovsg/FormSG/pull/6883) +- build: merge release 6.88.0 into develop [`#6882`](https://github.com/opengovsg/FormSG/pull/6882) +- build: release v6.88.0 [`#6881`](https://github.com/opengovsg/FormSG/pull/6881) +- chore: bump version to v6.89.0 [`1665a48`](https://github.com/opengovsg/FormSG/commit/1665a48b0ff133378c7126d3fedf8f1145f67111) + #### [v6.88.0](https://github.com/opengovsg/FormSG/compare/v6.87.0...v6.88.0) +> 9 November 2023 + - chore: add note to update guide to sync with file exts [`#6876`](https://github.com/opengovsg/FormSG/pull/6876) - fix(datepicker): webkit-related stylings [`#6875`](https://github.com/opengovsg/FormSG/pull/6875) - build: merge release 6.87.0 into develop [`#6879`](https://github.com/opengovsg/FormSG/pull/6879) - build: release v6.87.0 [`#6878`](https://github.com/opengovsg/FormSG/pull/6878) +- chore: bump version to v6.88.0 [`352ae5c`](https://github.com/opengovsg/FormSG/commit/352ae5c49ed30d73450364f8b4d6048e21f72ee2) #### [v6.87.0](https://github.com/opengovsg/FormSG/compare/v6.86.0...v6.87.0) diff --git a/frontend/package-lock.json b/frontend/package-lock.json index 599fcb5566..6dae895358 100644 --- a/frontend/package-lock.json +++ b/frontend/package-lock.json @@ -1,12 +1,12 @@ { "name": "form-frontend", - "version": "6.88.0", + "version": "6.89.0", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "form-frontend", - "version": "6.88.0", + "version": "6.89.0", "hasInstallScript": true, "dependencies": { "@chakra-ui/react": "^1.8.6", diff --git a/frontend/package.json b/frontend/package.json index 162f127ab9..26368530f7 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -1,6 +1,6 @@ { "name": "form-frontend", - "version": "6.88.0", + "version": "6.89.0", "homepage": ".", "private": true, "dependencies": { diff --git a/frontend/src/components/InlineMessage/InlineMessage.stories.tsx b/frontend/src/components/InlineMessage/InlineMessage.stories.tsx index 2181f21d0d..a74b3fa60d 100644 --- a/frontend/src/components/InlineMessage/InlineMessage.stories.tsx +++ b/frontend/src/components/InlineMessage/InlineMessage.stories.tsx @@ -41,6 +41,6 @@ Warning.args = { export const Error = InlineMessageTemplate.bind({}) Error.args = { variant: 'error', - children: `Only 30 MyInfo fields are allowed in Email mode (30/30). [Learn more](http://localhost:6006)`, + children: `Only 30 MyInfo fields are allowed (30/30). [Learn more](http://localhost:6006)`, useMarkdown: true, } diff --git a/frontend/src/features/admin-form/create/builder-and-design/BuilderAndDesignDrawer/FieldListDrawer/field-panels/MyInfoPanel.tsx b/frontend/src/features/admin-form/create/builder-and-design/BuilderAndDesignDrawer/FieldListDrawer/field-panels/MyInfoPanel.tsx index 5d728ddc30..b53afc0eb7 100644 --- a/frontend/src/features/admin-form/create/builder-and-design/BuilderAndDesignDrawer/FieldListDrawer/field-panels/MyInfoPanel.tsx +++ b/frontend/src/features/admin-form/create/builder-and-design/BuilderAndDesignDrawer/FieldListDrawer/field-panels/MyInfoPanel.tsx @@ -5,7 +5,12 @@ import { Box, Text } from '@chakra-ui/react' import { useFeatureIsOn, useGrowthBook } from '@growthbook/growthbook-react' import { featureFlags } from '~shared/constants' -import { AdminFormDto, FormAuthType, MyInfoAttribute } from '~shared/types' +import { + AdminFormDto, + FormAuthType, + FormResponseMode, + MyInfoAttribute, +} from '~shared/types' import { GUIDE_EMAIL_MODE } from '~constants/links' import { ADMINFORM_SETTINGS_SINGPASS_SUBROUTE } from '~constants/routes' @@ -200,7 +205,8 @@ export const MyInfoFieldPanel = () => { )} - {user?.betaFlags?.children ? ( + {user?.betaFlags?.children && + form?.responseMode === FormResponseMode.Email ? ( {(provided) => ( @@ -252,7 +258,7 @@ const MyInfoText = ({ return ( - {`Only 30 MyInfo fields are allowed in Email mode (${numMyInfoFields}/30). `} + {`Only 30 MyInfo fields are allowed (${numMyInfoFields}/30). `} Learn more diff --git a/package-lock.json b/package-lock.json index e8f4169600..554a33c83e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "FormSG", - "version": "6.88.0", + "version": "6.89.1", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "FormSG", - "version": "6.88.0", + "version": "6.89.1", "hasInstallScript": true, "dependencies": { "@aws-sdk/client-cloudwatch-logs": "^3.347.1", diff --git a/package.json b/package.json index 1dcf9047cd..342bd6a950 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "FormSG", "description": "Form Manager for Government", - "version": "6.88.0", + "version": "6.89.1", "homepage": "https://form.gov.sg", "authors": [ "FormSG " diff --git a/src/app/modules/submission/encrypt-submission/encrypt-submission.middleware.ts b/src/app/modules/submission/encrypt-submission/encrypt-submission.middleware.ts index c9e2de26c8..f6f07b88a8 100644 --- a/src/app/modules/submission/encrypt-submission/encrypt-submission.middleware.ts +++ b/src/app/modules/submission/encrypt-submission/encrypt-submission.middleware.ts @@ -430,32 +430,6 @@ export const validateStorageSubmission = async ( req.formsg.filteredResponses = responses return { parsedResponses, form: formDef } }) - .mapErr((error) => { - // TODO(FRM-1318): Set DB flag to true to harden submission validation after validation has similar error rates as email mode forms. - if ( - req.formsg.featureFlags.includes( - featureFlags.encryptionBoundaryShiftHardValidation, - ) - ) { - logger.error({ - message: 'Error processing responses', - meta: logMeta, - error, - }) - const { statusCode, errorMessage } = mapRouteError(error) - return res.status(statusCode).json({ - message: errorMessage, - }) - } - logger.warn({ - message: - 'Error processing responses, but proceeding with submission as submission have been validated client-side', - meta: logMeta, - error, - }) - req.formsg.filteredResponses = req.body.responses - return error - }) .andThen(({ parsedResponses, form }) => { // Validate MyInfo responses const { authType } = form @@ -511,8 +485,9 @@ export const validateStorageSubmission = async ( meta: logMeta, error, }) - return res.status(StatusCodes.INTERNAL_SERVER_ERROR).json({ - message: 'Error saving responses in req.body', + const { statusCode, errorMessage } = mapRouteError(error) + return res.status(statusCode).json({ + message: errorMessage, spcpSubmissionFailure, }) })