diff --git a/README.md b/README.md index 0acd8f560e..3898b123a6 100644 --- a/README.md +++ b/README.md @@ -42,7 +42,7 @@ The scripts folder is a dumping ground for various utility scripts and codemods. ## Running it locally -Running Tracker locally takes a few commands and a lot of RAM. See the instructions in the [app folder](app/README.md) +Running Tracker locally takes a few commands and a lot of RAM. See the instructions in the [k8s folder](k8s/README.md) ## Deploying to the cloud diff --git a/api/Dockerfile b/api/Dockerfile index a6f8ccd515..6c83e46870 100644 --- a/api/Dockerfile +++ b/api/Dockerfile @@ -1,7 +1,7 @@ # To build image: docker build --tag tracker-api:1.0 . # To run image: docker run --network=host --env-file ./.env tracker-api:1.0 # Build image -FROM node:alpine AS base +FROM node:20.16-alpine3.19 AS base WORKDIR /app diff --git a/api/cloudbuild.yaml b/api/cloudbuild.yaml index 150b246120..46c231ac80 100644 --- a/api/cloudbuild.yaml +++ b/api/cloudbuild.yaml @@ -5,7 +5,7 @@ steps: args: [ '-c', - 'docker run -d --network=cloudbuild -p=8529:8529 -e ARANGO_ROOT_PASSWORD=$_DB_PASS --name=arangodb arangodb/arangodb:3.10.4', + 'docker run -d --network=cloudbuild -p=8529:8529 -e ARANGO_ROOT_PASSWORD=$_DB_PASS --name=arangodb arangodb/arangodb:3.12.1', ] - name: mikewilliamson/wait-for diff --git a/api/docker-compose.yaml b/api/docker-compose.yaml index b61de778f1..b5a060f161 100644 --- a/api/docker-compose.yaml +++ b/api/docker-compose.yaml @@ -2,14 +2,14 @@ version: '3' services: nats: - image: nats:2.9.11-scratch + image: nats:2.10.16-scratch container_name: nats network_mode: "host" command: -js restart: always arangodb: - image: arangodb:3.10.5 + image: arangodb:3.12.1 container_name: arangodb environment: - ARANGO_ROOT_PASSWORD=test diff --git a/api/index.js b/api/index.js index f6e9008fbf..5c9bdb7f32 100644 --- a/api/index.js +++ b/api/index.js @@ -3,7 +3,7 @@ import { Database, aql } from 'arangojs' import { Server } from './src/server' import { createContext } from './src/create-context' import { createI18n } from './src/create-i18n' -import { connect, JSONCodec } from 'nats' +import { connect, JSONCodec, RetentionPolicy } from 'nats' import { collectionNames as collections } from './src/collection-names' const { @@ -43,8 +43,19 @@ const { const jsm = await nc.jetstreamManager() - await jsm.streams.add({ name: 'domains', subjects: ['domains.*'] }) - await jsm.streams.add({ name: 'domain-discovery', subjects: ['domains.*.discovery'] }) + await jsm.streams.add({ + name: 'SCANS', + subjects: [ + 'scans.requests', + 'scans.discovery', + 'scans.add_domain_to_easm', + 'scans.dns_scanner_results', + 'scans.dns_processor_results', + 'scans.web_scanner_results', + 'scans.web_processor_results', + ], + retention: RetentionPolicy.Workqueue, + }) // create a jetstream client: const js = nc.jetstream() diff --git a/api/package-lock.json b/api/package-lock.json index eab3a5cca8..f15864e627 100644 --- a/api/package-lock.json +++ b/api/package-lock.json @@ -20,7 +20,7 @@ "cors": "^2.8.5", "dataloader": "^2.0.0", "dotenv-safe": "^8.2.0", - "express": "^4.19.2", + "express": "^4.20.0", "express-request-language": "^1.1.15", "graphql": "^16.8.1", "graphql-depth-limit": "^1.1.0", @@ -36,7 +36,7 @@ "moment": "^2.29.4", "ms": "^2.1.3", "nats": "^2.18.0", - "notifications-node-client": "^8.0.0", + "notifications-node-client": "^8.2.1", "url-slug": "^3.0.2", "uuid": "^8.3.2", "validator": "^13.7.0" @@ -2949,14 +2949,14 @@ "integrity": "sha512-CtzORUwWTTOTqfVtHaKRJ0I1kNQd1bpn3sUh8I3nJDVY+5/M/Oe1DnEWzPQvqq/xPIIkzzzIP7mfCoAjFRvDhg==" }, "node_modules/@jridgewell/gen-mapping": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.2.tgz", - "integrity": "sha512-mh65xKQAzI6iBcFzwv28KVWSmCkdRBWoOh+bYQGW3+6OZvbbN3TqMGo5hqYxQniRcH9F2VZIoJCm4pa3BPDK/A==", + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", + "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==", "dev": true, "dependencies": { - "@jridgewell/set-array": "^1.0.1", + "@jridgewell/set-array": "^1.2.1", "@jridgewell/sourcemap-codec": "^1.4.10", - "@jridgewell/trace-mapping": "^0.3.9" + "@jridgewell/trace-mapping": "^0.3.24" }, "engines": { "node": ">=6.0.0" @@ -2972,23 +2972,23 @@ } }, "node_modules/@jridgewell/set-array": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz", - "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", + "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==", "dev": true, "engines": { "node": ">=6.0.0" } }, "node_modules/@jridgewell/source-map": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.2.tgz", - "integrity": "sha512-m7O9o2uR8k2ObDysZYzdfhb08VuEml5oWGiosa1VdaPZ/A6QyPkAJuwN0Q1lhULOf6B7MtQmHENS743hWtCrgw==", + "version": "0.3.6", + "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.6.tgz", + "integrity": "sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ==", "dev": true, "peer": true, "dependencies": { - "@jridgewell/gen-mapping": "^0.3.0", - "@jridgewell/trace-mapping": "^0.3.9" + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.25" } }, "node_modules/@jridgewell/sourcemap-codec": { @@ -2998,9 +2998,9 @@ "dev": true }, "node_modules/@jridgewell/trace-mapping": { - "version": "0.3.19", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.19.tgz", - "integrity": "sha512-kf37QtfW+Hwx/buWGMPcR60iF9ziHa6r/CZJIHbmcm4+0qrXiVdxegAH0F6yddEVQ7zdkjcGCgCzUu+BcbhQxw==", + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", "dev": true, "dependencies": { "@jridgewell/resolve-uri": "^3.1.0", @@ -3538,32 +3538,10 @@ "@types/node": "*" } }, - "node_modules/@types/eslint": { - "version": "8.21.2", - "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.21.2.tgz", - "integrity": "sha512-EMpxUyystd3uZVByZap1DACsMXvb82ypQnGn89e1Y0a+LYu3JJscUd/gqhRsVFDkaD2MIiWo0MT8EfXr3DGRKw==", - "dev": true, - "peer": true, - "dependencies": { - "@types/estree": "*", - "@types/json-schema": "*" - } - }, - "node_modules/@types/eslint-scope": { - "version": "3.7.4", - "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.4.tgz", - "integrity": "sha512-9K4zoImiZc3HlIp6AVUDE4CWYx22a+lhSZMYNpbjW04+YF0KWj4pJXnEMjdnFTiQibFFmElcsasJXDbdI/EPhA==", - "dev": true, - "peer": true, - "dependencies": { - "@types/eslint": "*", - "@types/estree": "*" - } - }, "node_modules/@types/estree": { - "version": "0.0.51", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-0.0.51.tgz", - "integrity": "sha512-CuPgU6f3eT/XgKKPqKd/gLZV1Xmvf1a2R5POBOGQa6uv82xpls89HU5zKeVoyR8XzHd1RGNOlQlvUe3CFkjWNQ==", + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz", + "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==", "dev": true, "peer": true }, @@ -3850,73 +3828,73 @@ } }, "node_modules/@webassemblyjs/ast": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.11.1.tgz", - "integrity": "sha512-ukBh14qFLjxTQNTXocdyksN5QdM28S1CxHt2rdskFyL+xFV7VremuBLVbmCePj+URalXBENx/9Lm7lnhihtCSw==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.12.1.tgz", + "integrity": "sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==", "dev": true, "peer": true, "dependencies": { - "@webassemblyjs/helper-numbers": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1" + "@webassemblyjs/helper-numbers": "1.11.6", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6" } }, "node_modules/@webassemblyjs/floating-point-hex-parser": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.11.1.tgz", - "integrity": "sha512-iGRfyc5Bq+NnNuX8b5hwBrRjzf0ocrJPI6GWFodBFzmFnyvrQ83SHKhmilCU/8Jv67i4GJZBMhEzltxzcNagtQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.11.6.tgz", + "integrity": "sha512-ejAj9hfRJ2XMsNHk/v6Fu2dGS+i4UaXBXGemOfQ/JfQ6mdQg/WXtwleQRLLS4OvfDhv8rYnVwH27YJLMyYsxhw==", "dev": true, "peer": true }, "node_modules/@webassemblyjs/helper-api-error": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.11.1.tgz", - "integrity": "sha512-RlhS8CBCXfRUR/cwo2ho9bkheSXG0+NwooXcc3PAILALf2QLdFyj7KGsKRbVc95hZnhnERon4kW/D3SZpp6Tcg==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.11.6.tgz", + "integrity": "sha512-o0YkoP4pVu4rN8aTJgAyj9hC2Sv5UlkzCHhxqWj8butaLvnpdc2jOwh4ewE6CX0txSfLn/UYaV/pheS2Txg//Q==", "dev": true, "peer": true }, "node_modules/@webassemblyjs/helper-buffer": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.11.1.tgz", - "integrity": "sha512-gwikF65aDNeeXa8JxXa2BAk+REjSyhrNC9ZwdT0f8jc4dQQeDQ7G4m0f2QCLPJiMTTO6wfDmRmj/pW0PsUvIcA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.12.1.tgz", + "integrity": "sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==", "dev": true, "peer": true }, "node_modules/@webassemblyjs/helper-numbers": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-numbers/-/helper-numbers-1.11.1.tgz", - "integrity": "sha512-vDkbxiB8zfnPdNK9Rajcey5C0w+QJugEglN0of+kmO8l7lDb77AnlKYQF7aarZuCrv+l0UvqL+68gSDr3k9LPQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-numbers/-/helper-numbers-1.11.6.tgz", + "integrity": "sha512-vUIhZ8LZoIWHBohiEObxVm6hwP034jwmc9kuq5GdHZH0wiLVLIPcMCdpJzG4C11cHoQ25TFIQj9kaVADVX7N3g==", "dev": true, "peer": true, "dependencies": { - "@webassemblyjs/floating-point-hex-parser": "1.11.1", - "@webassemblyjs/helper-api-error": "1.11.1", + "@webassemblyjs/floating-point-hex-parser": "1.11.6", + "@webassemblyjs/helper-api-error": "1.11.6", "@xtuc/long": "4.2.2" } }, "node_modules/@webassemblyjs/helper-wasm-bytecode": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.11.1.tgz", - "integrity": "sha512-PvpoOGiJwXeTrSf/qfudJhwlvDQxFgelbMqtq52WWiXC6Xgg1IREdngmPN3bs4RoO83PnL/nFrxucXj1+BX62Q==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.11.6.tgz", + "integrity": "sha512-sFFHKwcmBprO9e7Icf0+gddyWYDViL8bpPjJJl0WHxCdETktXdmtWLGVzoHbqUcY4Be1LkNfwTmXOJUFZYSJdA==", "dev": true, "peer": true }, "node_modules/@webassemblyjs/helper-wasm-section": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.11.1.tgz", - "integrity": "sha512-10P9No29rYX1j7F3EVPX3JvGPQPae+AomuSTPiF9eBQeChHI6iqjMIwR9JmOJXwpnn/oVGDk7I5IlskuMwU/pg==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.12.1.tgz", + "integrity": "sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==", "dev": true, "peer": true, "dependencies": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-buffer": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/wasm-gen": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/wasm-gen": "1.12.1" } }, "node_modules/@webassemblyjs/ieee754": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.11.1.tgz", - "integrity": "sha512-hJ87QIPtAMKbFq6CGTkZYJivEwZDbQUgYd3qKSadTNOhVY7p+gfP6Sr0lLRVTaG1JjFj+r3YchoqRYxNH3M0GQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.11.6.tgz", + "integrity": "sha512-LM4p2csPNvbij6U1f19v6WR56QZ8JcHg3QIJTlSwzFcmx6WSORicYj6I63f9yU1kEUtrpG+kjkiIAkevHpDXrg==", "dev": true, "peer": true, "dependencies": { @@ -3924,9 +3902,9 @@ } }, "node_modules/@webassemblyjs/leb128": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.11.1.tgz", - "integrity": "sha512-BJ2P0hNZ0u+Th1YZXJpzW6miwqQUGcIHT1G/sf72gLVD9DZ5AdYTqPNbHZh6K1M5VmKvFXwGSWZADz+qBWxeRw==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.11.6.tgz", + "integrity": "sha512-m7a0FhE67DQXgouf1tbN5XQcdWoNgaAuoULHIfGFIEVKA6tu/edls6XnIlkmS6FrXAquJRPni3ZZKjw6FSPjPQ==", "dev": true, "peer": true, "dependencies": { @@ -3934,79 +3912,79 @@ } }, "node_modules/@webassemblyjs/utf8": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.11.1.tgz", - "integrity": "sha512-9kqcxAEdMhiwQkHpkNiorZzqpGrodQQ2IGrHHxCy+Ozng0ofyMA0lTqiLkVs1uzTRejX+/O0EOT7KxqVPuXosQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.11.6.tgz", + "integrity": "sha512-vtXf2wTQ3+up9Zsg8sa2yWiQpzSsMyXj0qViVP6xKGCUT8p8YJ6HqI7l5eCnWx1T/FYdsv07HQs2wTFbbof/RA==", "dev": true, "peer": true }, "node_modules/@webassemblyjs/wasm-edit": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.11.1.tgz", - "integrity": "sha512-g+RsupUC1aTHfR8CDgnsVRVZFJqdkFHpsHMfJuWQzWU3tvnLC07UqHICfP+4XyL2tnr1amvl1Sdp06TnYCmVkA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.12.1.tgz", + "integrity": "sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==", "dev": true, "peer": true, "dependencies": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-buffer": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/helper-wasm-section": "1.11.1", - "@webassemblyjs/wasm-gen": "1.11.1", - "@webassemblyjs/wasm-opt": "1.11.1", - "@webassemblyjs/wasm-parser": "1.11.1", - "@webassemblyjs/wast-printer": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/helper-wasm-section": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-opt": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1", + "@webassemblyjs/wast-printer": "1.12.1" } }, "node_modules/@webassemblyjs/wasm-gen": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.11.1.tgz", - "integrity": "sha512-F7QqKXwwNlMmsulj6+O7r4mmtAlCWfO/0HdgOxSklZfQcDu0TpLiD1mRt/zF25Bk59FIjEuGAIyn5ei4yMfLhA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.12.1.tgz", + "integrity": "sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==", "dev": true, "peer": true, "dependencies": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/ieee754": "1.11.1", - "@webassemblyjs/leb128": "1.11.1", - "@webassemblyjs/utf8": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/ieee754": "1.11.6", + "@webassemblyjs/leb128": "1.11.6", + "@webassemblyjs/utf8": "1.11.6" } }, "node_modules/@webassemblyjs/wasm-opt": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.11.1.tgz", - "integrity": "sha512-VqnkNqnZlU5EB64pp1l7hdm3hmQw7Vgqa0KF/KCNO9sIpI6Fk6brDEiX+iCOYrvMuBWDws0NkTOxYEb85XQHHw==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.12.1.tgz", + "integrity": "sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==", "dev": true, "peer": true, "dependencies": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-buffer": "1.11.1", - "@webassemblyjs/wasm-gen": "1.11.1", - "@webassemblyjs/wasm-parser": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1" } }, "node_modules/@webassemblyjs/wasm-parser": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.11.1.tgz", - "integrity": "sha512-rrBujw+dJu32gYB7/Lup6UhdkPx9S9SnobZzRVL7VcBH9Bt9bCBLEuX/YXOOtBsOZ4NQrRykKhffRWHvigQvOA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.12.1.tgz", + "integrity": "sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==", "dev": true, "peer": true, "dependencies": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-api-error": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/ieee754": "1.11.1", - "@webassemblyjs/leb128": "1.11.1", - "@webassemblyjs/utf8": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-api-error": "1.11.6", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/ieee754": "1.11.6", + "@webassemblyjs/leb128": "1.11.6", + "@webassemblyjs/utf8": "1.11.6" } }, "node_modules/@webassemblyjs/wast-printer": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.11.1.tgz", - "integrity": "sha512-IQboUWM4eKzWW+N/jij2sRatKMh99QEelo3Eb2q0qXkvPRISAj8Qxtmw5itwqK+TTkBuUIE45AxYPToqPtL5gg==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.12.1.tgz", + "integrity": "sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==", "dev": true, "peer": true, "dependencies": { - "@webassemblyjs/ast": "1.11.1", + "@webassemblyjs/ast": "1.12.1", "@xtuc/long": "4.2.2" } }, @@ -4389,11 +4367,11 @@ } }, "node_modules/axios": { - "version": "1.6.1", - "resolved": "https://registry.npmjs.org/axios/-/axios-1.6.1.tgz", - "integrity": "sha512-vfBmhDpKafglh0EldBEbVuoe7DyAavGSLWhuSm5ZSEKQnHhBf0xAAwybbNH1IkrJNGnS/VG4I5yxig1pCEXE4g==", + "version": "1.7.4", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.7.4.tgz", + "integrity": "sha512-DukmaFRnY6AzAALSH4J2M3k6PkaC+MfaAGdEERRWcC9q3/TWQwLpHR8ZRLKTdQ3aBDL64EdluRDjJqKw+BPZEw==", "dependencies": { - "follow-redirects": "^1.15.0", + "follow-redirects": "^1.15.6", "form-data": "^4.0.0", "proxy-from-env": "^1.1.0" } @@ -4778,9 +4756,9 @@ } }, "node_modules/body-parser": { - "version": "1.20.2", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", - "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", + "version": "1.20.3", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", + "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", "dependencies": { "bytes": "3.1.2", "content-type": "~1.0.5", @@ -4790,7 +4768,7 @@ "http-errors": "2.0.0", "iconv-lite": "0.4.24", "on-finished": "2.4.1", - "qs": "6.11.0", + "qs": "6.13.0", "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" @@ -4813,6 +4791,20 @@ "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" }, + "node_modules/body-parser/node_modules/qs": { + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz", + "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==", + "dependencies": { + "side-channel": "^1.0.6" + }, + "engines": { + "node": ">=0.6" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", @@ -4926,12 +4918,18 @@ } }, "node_modules/call-bind": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", - "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.7.tgz", + "integrity": "sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==", "dependencies": { - "function-bind": "^1.1.1", - "get-intrinsic": "^1.0.2" + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "set-function-length": "^1.2.1" + }, + "engines": { + "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" @@ -5573,6 +5571,22 @@ "clone": "^1.0.2" } }, + "node_modules/define-data-property": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", + "integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==", + "dependencies": { + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "gopd": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/define-properties": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", @@ -5799,9 +5813,9 @@ } }, "node_modules/enhanced-resolve": { - "version": "5.12.0", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.12.0.tgz", - "integrity": "sha512-QHTXI/sZQmko1cbDoNAa3mJ5qhWUUNAq3vR0/YiD379fWQrcfuoX1+HW2S0MTt7XmoPLapdaDKUtelUSPic7hQ==", + "version": "5.17.1", + "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.17.1.tgz", + "integrity": "sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg==", "dev": true, "peer": true, "dependencies": { @@ -5867,10 +5881,29 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/es-define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.0.tgz", + "integrity": "sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==", + "dependencies": { + "get-intrinsic": "^1.2.4" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-errors": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", + "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", + "engines": { + "node": ">= 0.4" + } + }, "node_modules/es-module-lexer": { - "version": "0.9.3", - "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-0.9.3.tgz", - "integrity": "sha512-1HQ2M2sPtxwnvOvT1ZClHyQDiggdNjURWpY2we6aMKCQiUVxTmVs2UYPLIrD84sS+kMdUwfBSylbJPwNnBrnHQ==", + "version": "1.5.4", + "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.5.4.tgz", + "integrity": "sha512-MVNK56NiMrOwitFB7cqDwq0CQutbw+0BvLshJSse0MUNU+y1FC3bUS/AQg7oUng+/wKrrki7JfmwtVHkVfPLlw==", "dev": true, "peer": true }, @@ -6690,36 +6723,36 @@ } }, "node_modules/express": { - "version": "4.19.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", - "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", + "version": "4.20.0", + "resolved": "https://registry.npmjs.org/express/-/express-4.20.0.tgz", + "integrity": "sha512-pLdae7I6QqShF5PnNTCVn4hI91Dx0Grkn2+IAsMTgMIKuQVte2dN9PeGSSAME2FR8anOhVA62QDIUaWVfEXVLw==", "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.2", + "body-parser": "1.20.3", "content-disposition": "0.5.4", "content-type": "~1.0.4", "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "etag": "~1.8.1", "finalhandler": "1.2.0", "fresh": "0.5.2", "http-errors": "2.0.0", - "merge-descriptors": "1.0.1", + "merge-descriptors": "1.0.3", "methods": "~1.1.2", "on-finished": "2.4.1", "parseurl": "~1.3.3", - "path-to-regexp": "0.1.7", + "path-to-regexp": "0.1.10", "proxy-addr": "~2.0.7", "qs": "6.11.0", "range-parser": "~1.2.1", "safe-buffer": "5.2.1", - "send": "0.18.0", - "serve-static": "1.15.0", + "send": "0.19.0", + "serve-static": "1.16.0", "setprototypeof": "1.2.0", "statuses": "2.0.1", "type-is": "~1.6.18", @@ -6755,6 +6788,14 @@ "ms": "2.0.0" } }, + "node_modules/express/node_modules/encodeurl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", + "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", + "engines": { + "node": ">= 0.8" + } + }, "node_modules/express/node_modules/ms": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", @@ -7099,9 +7140,12 @@ } }, "node_modules/function-bind": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", - "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", + "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } }, "node_modules/functional-red-black-tree": { "version": "1.0.1", @@ -7134,13 +7178,18 @@ } }, "node_modules/get-intrinsic": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.1.1.tgz", - "integrity": "sha512-kWZrnVM42QCiEA2Ig1bG8zjoIMOgxWwYCEeNdwY6Tv/cOSeGpcoX4pXHfKUxNKVoArnrEr2e9srnAxxGIraS9Q==", + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.4.tgz", + "integrity": "sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==", "dependencies": { - "function-bind": "^1.1.1", - "has": "^1.0.3", - "has-symbols": "^1.0.1" + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "hasown": "^2.0.0" + }, + "engines": { + "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" @@ -7278,10 +7327,21 @@ "node": ">=8" } }, + "node_modules/gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "dependencies": { + "get-intrinsic": "^1.1.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/graceful-fs": { - "version": "4.2.10", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz", - "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==", + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", "dev": true }, "node_modules/graphql": { @@ -7406,6 +7466,7 @@ "version": "1.0.3", "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dev": true, "dependencies": { "function-bind": "^1.1.1" }, @@ -7431,10 +7492,32 @@ "node": ">=4" } }, - "node_modules/has-symbols": { + "node_modules/has-property-descriptors": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.2.tgz", - "integrity": "sha512-chXa79rL/UC2KlX17jo3vRGz0azaWEx5tGqZg5pO3NUyEJVB17dMruQlzCCOfUvElghKcm5194+BCRvi2Rv/Gw==", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz", + "integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==", + "dependencies": { + "es-define-property": "^1.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-proto": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.3.tgz", + "integrity": "sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", "engines": { "node": ">= 0.4" }, @@ -7457,6 +7540,17 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/hasown": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", + "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", + "dependencies": { + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, "node_modules/hexoid": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/hexoid/-/hexoid-1.0.0.tgz", @@ -10716,9 +10810,12 @@ } }, "node_modules/merge-descriptors": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", - "integrity": "sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E=" + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", + "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==", + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } }, "node_modules/merge-stream": { "version": "2.0.0", @@ -11025,12 +11122,12 @@ } }, "node_modules/notifications-node-client": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/notifications-node-client/-/notifications-node-client-8.0.0.tgz", - "integrity": "sha512-65BxorFYVFOpJ9c2lud/4Ju+Bfn3L/vkih+FuzMhBw1wcOPjwgu4doVH6xO91fHYiAi/0uIx0Mc+NorXeANMHw==", + "version": "8.2.1", + "resolved": "https://registry.npmjs.org/notifications-node-client/-/notifications-node-client-8.2.1.tgz", + "integrity": "sha512-wyZh/NbjN8S2uQX18utYtCyC726BBaGeTc4HeUpdhZv5sYKuaQY94N31v9syh8SzVgehyMzW37y08EePmi+k3Q==", "dependencies": { - "axios": "^1.6.1", - "jsonwebtoken": "^9.0.0" + "axios": "^1.7.2", + "jsonwebtoken": "^9.0.2" }, "engines": { "node": ">=14.17.3", @@ -11064,9 +11161,12 @@ } }, "node_modules/object-inspect": { - "version": "1.11.0", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.11.0.tgz", - "integrity": "sha512-jp7ikS6Sd3GxQfZJPyH3cjcbJF6GZPClgdV+EFygjFLQ5FmW/dRUnTd9PQ9k0JhoNDabWFbpF1yCdSWCC6gexg==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.2.tgz", + "integrity": "sha512-IRZSRuzJiynemAXPYtPe5BoI/RESNYR7TYm50MC5Mqbd3Jmw5y790sErYw3V6SryFJD64b74qQQs9wn5Bg/k3g==", + "engines": { + "node": ">= 0.4" + }, "funding": { "url": "https://github.com/sponsors/ljharb" } @@ -11441,9 +11541,9 @@ "dev": true }, "node_modules/path-to-regexp": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", - "integrity": "sha1-32BBeABfUi8V60SQ5yR6G/qmf4w=" + "version": "0.1.10", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.10.tgz", + "integrity": "sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w==" }, "node_modules/path-type": { "version": "4.0.0", @@ -12164,9 +12264,9 @@ } }, "node_modules/schema-utils": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.1.1.tgz", - "integrity": "sha512-Y5PQxS4ITlC+EahLuXaY86TXfR7Dc5lw294alXOq86JAHCihAIZfqv8nNCWvaEJvaC51uN9hbLGeV0cFBdH+Fw==", + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.3.0.tgz", + "integrity": "sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==", "dev": true, "peer": true, "dependencies": { @@ -12192,9 +12292,9 @@ } }, "node_modules/send": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", - "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "version": "0.19.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", + "integrity": "sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==", "dependencies": { "debug": "2.6.9", "depd": "2.0.0", @@ -12228,9 +12328,9 @@ "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==" }, "node_modules/serialize-javascript": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.0.tgz", - "integrity": "sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag==", + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz", + "integrity": "sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==", "dev": true, "peer": true, "dependencies": { @@ -12238,9 +12338,9 @@ } }, "node_modules/serve-static": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.15.0.tgz", - "integrity": "sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==", + "version": "1.16.0", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.16.0.tgz", + "integrity": "sha512-pDLK8zwl2eKaYrs8mrPZBJua4hMplRWJ1tIFksVC3FtBEBnl8dxgeHtsaMS8DhS9i4fLObaon6ABoc4/hQGdPA==", "dependencies": { "encodeurl": "~1.0.2", "escape-html": "~1.0.3", @@ -12251,6 +12351,58 @@ "node": ">= 0.8.0" } }, + "node_modules/serve-static/node_modules/debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "dependencies": { + "ms": "2.0.0" + } + }, + "node_modules/serve-static/node_modules/debug/node_modules/ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==" + }, + "node_modules/serve-static/node_modules/send": { + "version": "0.18.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", + "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "dependencies": { + "debug": "2.6.9", + "depd": "2.0.0", + "destroy": "1.2.0", + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "etag": "~1.8.1", + "fresh": "0.5.2", + "http-errors": "2.0.0", + "mime": "1.6.0", + "ms": "2.1.3", + "on-finished": "2.4.1", + "range-parser": "~1.2.1", + "statuses": "2.0.1" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/set-function-length": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", + "integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==", + "dependencies": { + "define-data-property": "^1.1.4", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + } + }, "node_modules/setprototypeof": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", @@ -12302,13 +12454,17 @@ } }, "node_modules/side-channel": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", - "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.6.tgz", + "integrity": "sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==", "dependencies": { - "call-bind": "^1.0.0", - "get-intrinsic": "^1.0.2", - "object-inspect": "^1.9.0" + "call-bind": "^1.0.7", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.4", + "object-inspect": "^1.13.1" + }, + "engines": { + "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" @@ -12789,14 +12945,14 @@ } }, "node_modules/terser": { - "version": "5.14.2", - "resolved": "https://registry.npmjs.org/terser/-/terser-5.14.2.tgz", - "integrity": "sha512-oL0rGeM/WFQCUd0y2QrWxYnq7tfSuKBiqTjRPWrRgB46WD/kiwHwF8T23z78H6Q6kGCuuHcPB+KULHRdxvVGQA==", + "version": "5.31.6", + "resolved": "https://registry.npmjs.org/terser/-/terser-5.31.6.tgz", + "integrity": "sha512-PQ4DAriWzKj+qgehQ7LK5bQqCFNMmlhjR2PFFLuqGCpuCAauxemVBWwWOxo3UIwWQx8+Pr61Df++r76wDmkQBg==", "dev": true, "peer": true, "dependencies": { - "@jridgewell/source-map": "^0.3.2", - "acorn": "^8.5.0", + "@jridgewell/source-map": "^0.3.3", + "acorn": "^8.8.2", "commander": "^2.20.0", "source-map-support": "~0.5.20" }, @@ -12808,18 +12964,17 @@ } }, "node_modules/terser-webpack-plugin": { - "version": "5.2.4", - "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.2.4.tgz", - "integrity": "sha512-E2CkNMN+1cho04YpdANyRrn8CyN4yMy+WdFKZIySFZrGXZxJwJP6PMNGGc/Mcr6qygQHUUqRxnAPmi0M9f00XA==", + "version": "5.3.10", + "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.10.tgz", + "integrity": "sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==", "dev": true, "peer": true, "dependencies": { - "jest-worker": "^27.0.6", - "p-limit": "^3.1.0", + "@jridgewell/trace-mapping": "^0.3.20", + "jest-worker": "^27.4.5", "schema-utils": "^3.1.1", - "serialize-javascript": "^6.0.0", - "source-map": "^0.6.1", - "terser": "^5.7.2" + "serialize-javascript": "^6.0.1", + "terser": "^5.26.0" }, "engines": { "node": ">= 10.13.0" @@ -12843,36 +12998,10 @@ } } }, - "node_modules/terser-webpack-plugin/node_modules/p-limit": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", - "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", - "dev": true, - "peer": true, - "dependencies": { - "yocto-queue": "^0.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/terser-webpack-plugin/node_modules/source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true, - "peer": true, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/terser/node_modules/acorn": { - "version": "8.7.1", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.7.1.tgz", - "integrity": "sha512-Xx54uLJQZ19lKygFXOWsscKUbsBZW0CPykPhVQdhIeIwrbPmJzqeASDInc8nKBnp/JT6igTs82qPXz069H8I/A==", + "version": "8.12.1", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.12.1.tgz", + "integrity": "sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg==", "dev": true, "peer": true, "bin": { @@ -13422,9 +13551,9 @@ } }, "node_modules/watchpack": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.0.tgz", - "integrity": "sha512-Lcvm7MGST/4fup+ifyKi2hjyIAwcdI4HRgtvTpIUxBRhB+RFtUh8XtDOxUfctVCnhVi+QQj49i91OyvzkJl6cg==", + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.2.tgz", + "integrity": "sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==", "dev": true, "peer": true, "dependencies": { @@ -13454,35 +13583,34 @@ } }, "node_modules/webpack": { - "version": "5.76.1", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.76.1.tgz", - "integrity": "sha512-4+YIK4Abzv8172/SGqObnUjaIHjLEuUasz9EwQj/9xmPPkYJy2Mh03Q/lJfSD3YLzbxy5FeTq5Uw0323Oh6SJQ==", + "version": "5.94.0", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.94.0.tgz", + "integrity": "sha512-KcsGn50VT+06JH/iunZJedYGUJS5FGjow8wb9c0v5n1Om8O1g4L6LjtfxwlXIATopoQu+vOXXa7gYisWxCoPyg==", "dev": true, "peer": true, "dependencies": { - "@types/eslint-scope": "^3.7.3", - "@types/estree": "^0.0.51", - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/wasm-edit": "1.11.1", - "@webassemblyjs/wasm-parser": "1.11.1", + "@types/estree": "^1.0.5", + "@webassemblyjs/ast": "^1.12.1", + "@webassemblyjs/wasm-edit": "^1.12.1", + "@webassemblyjs/wasm-parser": "^1.12.1", "acorn": "^8.7.1", - "acorn-import-assertions": "^1.7.6", - "browserslist": "^4.14.5", + "acorn-import-attributes": "^1.9.5", + "browserslist": "^4.21.10", "chrome-trace-event": "^1.0.2", - "enhanced-resolve": "^5.10.0", - "es-module-lexer": "^0.9.0", + "enhanced-resolve": "^5.17.1", + "es-module-lexer": "^1.2.1", "eslint-scope": "5.1.1", "events": "^3.2.0", "glob-to-regexp": "^0.4.1", - "graceful-fs": "^4.2.9", + "graceful-fs": "^4.2.11", "json-parse-even-better-errors": "^2.3.1", "loader-runner": "^4.2.0", "mime-types": "^2.1.27", "neo-async": "^2.6.2", - "schema-utils": "^3.1.0", + "schema-utils": "^3.2.0", "tapable": "^2.1.1", - "terser-webpack-plugin": "^5.1.3", - "watchpack": "^2.4.0", + "terser-webpack-plugin": "^5.3.10", + "watchpack": "^2.4.1", "webpack-sources": "^3.2.3" }, "bin": { @@ -13512,9 +13640,9 @@ } }, "node_modules/webpack/node_modules/acorn": { - "version": "8.8.2", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz", - "integrity": "sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw==", + "version": "8.12.1", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.12.1.tgz", + "integrity": "sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg==", "dev": true, "peer": true, "bin": { @@ -13524,10 +13652,10 @@ "node": ">=0.4.0" } }, - "node_modules/webpack/node_modules/acorn-import-assertions": { - "version": "1.7.6", - "resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.7.6.tgz", - "integrity": "sha512-FlVvVFA1TX6l3lp8VjDnYYq7R1nyW6x3svAt4nDgrWQ9SBaSh9CnbwgSUTasgfNfOG5HlM1ehugCvM+hjo56LA==", + "node_modules/webpack/node_modules/acorn-import-attributes": { + "version": "1.9.5", + "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz", + "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==", "dev": true, "peer": true, "peerDependencies": { @@ -13794,19 +13922,6 @@ "engines": { "node": ">=6" } - }, - "node_modules/yocto-queue": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", - "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", - "dev": true, - "peer": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } } }, "dependencies": { @@ -15868,14 +15983,14 @@ "integrity": "sha512-CtzORUwWTTOTqfVtHaKRJ0I1kNQd1bpn3sUh8I3nJDVY+5/M/Oe1DnEWzPQvqq/xPIIkzzzIP7mfCoAjFRvDhg==" }, "@jridgewell/gen-mapping": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.2.tgz", - "integrity": "sha512-mh65xKQAzI6iBcFzwv28KVWSmCkdRBWoOh+bYQGW3+6OZvbbN3TqMGo5hqYxQniRcH9F2VZIoJCm4pa3BPDK/A==", + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", + "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==", "dev": true, "requires": { - "@jridgewell/set-array": "^1.0.1", + "@jridgewell/set-array": "^1.2.1", "@jridgewell/sourcemap-codec": "^1.4.10", - "@jridgewell/trace-mapping": "^0.3.9" + "@jridgewell/trace-mapping": "^0.3.24" } }, "@jridgewell/resolve-uri": { @@ -15885,20 +16000,20 @@ "dev": true }, "@jridgewell/set-array": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz", - "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", + "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==", "dev": true }, "@jridgewell/source-map": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.2.tgz", - "integrity": "sha512-m7O9o2uR8k2ObDysZYzdfhb08VuEml5oWGiosa1VdaPZ/A6QyPkAJuwN0Q1lhULOf6B7MtQmHENS743hWtCrgw==", + "version": "0.3.6", + "resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.6.tgz", + "integrity": "sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ==", "dev": true, "peer": true, "requires": { - "@jridgewell/gen-mapping": "^0.3.0", - "@jridgewell/trace-mapping": "^0.3.9" + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.25" } }, "@jridgewell/sourcemap-codec": { @@ -15908,9 +16023,9 @@ "dev": true }, "@jridgewell/trace-mapping": { - "version": "0.3.19", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.19.tgz", - "integrity": "sha512-kf37QtfW+Hwx/buWGMPcR60iF9ziHa6r/CZJIHbmcm4+0qrXiVdxegAH0F6yddEVQ7zdkjcGCgCzUu+BcbhQxw==", + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", "dev": true, "requires": { "@jridgewell/resolve-uri": "^3.1.0", @@ -16351,32 +16466,10 @@ "@types/node": "*" } }, - "@types/eslint": { - "version": "8.21.2", - "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.21.2.tgz", - "integrity": "sha512-EMpxUyystd3uZVByZap1DACsMXvb82ypQnGn89e1Y0a+LYu3JJscUd/gqhRsVFDkaD2MIiWo0MT8EfXr3DGRKw==", - "dev": true, - "peer": true, - "requires": { - "@types/estree": "*", - "@types/json-schema": "*" - } - }, - "@types/eslint-scope": { - "version": "3.7.4", - "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.4.tgz", - "integrity": "sha512-9K4zoImiZc3HlIp6AVUDE4CWYx22a+lhSZMYNpbjW04+YF0KWj4pJXnEMjdnFTiQibFFmElcsasJXDbdI/EPhA==", - "dev": true, - "peer": true, - "requires": { - "@types/eslint": "*", - "@types/estree": "*" - } - }, "@types/estree": { - "version": "0.0.51", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-0.0.51.tgz", - "integrity": "sha512-CuPgU6f3eT/XgKKPqKd/gLZV1Xmvf1a2R5POBOGQa6uv82xpls89HU5zKeVoyR8XzHd1RGNOlQlvUe3CFkjWNQ==", + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz", + "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==", "dev": true, "peer": true }, @@ -16609,73 +16702,73 @@ } }, "@webassemblyjs/ast": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.11.1.tgz", - "integrity": "sha512-ukBh14qFLjxTQNTXocdyksN5QdM28S1CxHt2rdskFyL+xFV7VremuBLVbmCePj+URalXBENx/9Lm7lnhihtCSw==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.12.1.tgz", + "integrity": "sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==", "dev": true, "peer": true, "requires": { - "@webassemblyjs/helper-numbers": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1" + "@webassemblyjs/helper-numbers": "1.11.6", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6" } }, "@webassemblyjs/floating-point-hex-parser": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.11.1.tgz", - "integrity": "sha512-iGRfyc5Bq+NnNuX8b5hwBrRjzf0ocrJPI6GWFodBFzmFnyvrQ83SHKhmilCU/8Jv67i4GJZBMhEzltxzcNagtQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.11.6.tgz", + "integrity": "sha512-ejAj9hfRJ2XMsNHk/v6Fu2dGS+i4UaXBXGemOfQ/JfQ6mdQg/WXtwleQRLLS4OvfDhv8rYnVwH27YJLMyYsxhw==", "dev": true, "peer": true }, "@webassemblyjs/helper-api-error": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.11.1.tgz", - "integrity": "sha512-RlhS8CBCXfRUR/cwo2ho9bkheSXG0+NwooXcc3PAILALf2QLdFyj7KGsKRbVc95hZnhnERon4kW/D3SZpp6Tcg==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.11.6.tgz", + "integrity": "sha512-o0YkoP4pVu4rN8aTJgAyj9hC2Sv5UlkzCHhxqWj8butaLvnpdc2jOwh4ewE6CX0txSfLn/UYaV/pheS2Txg//Q==", "dev": true, "peer": true }, "@webassemblyjs/helper-buffer": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.11.1.tgz", - "integrity": "sha512-gwikF65aDNeeXa8JxXa2BAk+REjSyhrNC9ZwdT0f8jc4dQQeDQ7G4m0f2QCLPJiMTTO6wfDmRmj/pW0PsUvIcA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.12.1.tgz", + "integrity": "sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==", "dev": true, "peer": true }, "@webassemblyjs/helper-numbers": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-numbers/-/helper-numbers-1.11.1.tgz", - "integrity": "sha512-vDkbxiB8zfnPdNK9Rajcey5C0w+QJugEglN0of+kmO8l7lDb77AnlKYQF7aarZuCrv+l0UvqL+68gSDr3k9LPQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-numbers/-/helper-numbers-1.11.6.tgz", + "integrity": "sha512-vUIhZ8LZoIWHBohiEObxVm6hwP034jwmc9kuq5GdHZH0wiLVLIPcMCdpJzG4C11cHoQ25TFIQj9kaVADVX7N3g==", "dev": true, "peer": true, "requires": { - "@webassemblyjs/floating-point-hex-parser": "1.11.1", - "@webassemblyjs/helper-api-error": "1.11.1", + "@webassemblyjs/floating-point-hex-parser": "1.11.6", + "@webassemblyjs/helper-api-error": "1.11.6", "@xtuc/long": "4.2.2" } }, "@webassemblyjs/helper-wasm-bytecode": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.11.1.tgz", - "integrity": "sha512-PvpoOGiJwXeTrSf/qfudJhwlvDQxFgelbMqtq52WWiXC6Xgg1IREdngmPN3bs4RoO83PnL/nFrxucXj1+BX62Q==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.11.6.tgz", + "integrity": "sha512-sFFHKwcmBprO9e7Icf0+gddyWYDViL8bpPjJJl0WHxCdETktXdmtWLGVzoHbqUcY4Be1LkNfwTmXOJUFZYSJdA==", "dev": true, "peer": true }, "@webassemblyjs/helper-wasm-section": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.11.1.tgz", - "integrity": "sha512-10P9No29rYX1j7F3EVPX3JvGPQPae+AomuSTPiF9eBQeChHI6iqjMIwR9JmOJXwpnn/oVGDk7I5IlskuMwU/pg==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.12.1.tgz", + "integrity": "sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==", "dev": true, "peer": true, "requires": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-buffer": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/wasm-gen": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/wasm-gen": "1.12.1" } }, "@webassemblyjs/ieee754": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.11.1.tgz", - "integrity": "sha512-hJ87QIPtAMKbFq6CGTkZYJivEwZDbQUgYd3qKSadTNOhVY7p+gfP6Sr0lLRVTaG1JjFj+r3YchoqRYxNH3M0GQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.11.6.tgz", + "integrity": "sha512-LM4p2csPNvbij6U1f19v6WR56QZ8JcHg3QIJTlSwzFcmx6WSORicYj6I63f9yU1kEUtrpG+kjkiIAkevHpDXrg==", "dev": true, "peer": true, "requires": { @@ -16683,9 +16776,9 @@ } }, "@webassemblyjs/leb128": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.11.1.tgz", - "integrity": "sha512-BJ2P0hNZ0u+Th1YZXJpzW6miwqQUGcIHT1G/sf72gLVD9DZ5AdYTqPNbHZh6K1M5VmKvFXwGSWZADz+qBWxeRw==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.11.6.tgz", + "integrity": "sha512-m7a0FhE67DQXgouf1tbN5XQcdWoNgaAuoULHIfGFIEVKA6tu/edls6XnIlkmS6FrXAquJRPni3ZZKjw6FSPjPQ==", "dev": true, "peer": true, "requires": { @@ -16693,79 +16786,79 @@ } }, "@webassemblyjs/utf8": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.11.1.tgz", - "integrity": "sha512-9kqcxAEdMhiwQkHpkNiorZzqpGrodQQ2IGrHHxCy+Ozng0ofyMA0lTqiLkVs1uzTRejX+/O0EOT7KxqVPuXosQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.11.6.tgz", + "integrity": "sha512-vtXf2wTQ3+up9Zsg8sa2yWiQpzSsMyXj0qViVP6xKGCUT8p8YJ6HqI7l5eCnWx1T/FYdsv07HQs2wTFbbof/RA==", "dev": true, "peer": true }, "@webassemblyjs/wasm-edit": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.11.1.tgz", - "integrity": "sha512-g+RsupUC1aTHfR8CDgnsVRVZFJqdkFHpsHMfJuWQzWU3tvnLC07UqHICfP+4XyL2tnr1amvl1Sdp06TnYCmVkA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.12.1.tgz", + "integrity": "sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==", "dev": true, "peer": true, "requires": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-buffer": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/helper-wasm-section": "1.11.1", - "@webassemblyjs/wasm-gen": "1.11.1", - "@webassemblyjs/wasm-opt": "1.11.1", - "@webassemblyjs/wasm-parser": "1.11.1", - "@webassemblyjs/wast-printer": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/helper-wasm-section": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-opt": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1", + "@webassemblyjs/wast-printer": "1.12.1" } }, "@webassemblyjs/wasm-gen": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.11.1.tgz", - "integrity": "sha512-F7QqKXwwNlMmsulj6+O7r4mmtAlCWfO/0HdgOxSklZfQcDu0TpLiD1mRt/zF25Bk59FIjEuGAIyn5ei4yMfLhA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.12.1.tgz", + "integrity": "sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==", "dev": true, "peer": true, "requires": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/ieee754": "1.11.1", - "@webassemblyjs/leb128": "1.11.1", - "@webassemblyjs/utf8": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/ieee754": "1.11.6", + "@webassemblyjs/leb128": "1.11.6", + "@webassemblyjs/utf8": "1.11.6" } }, "@webassemblyjs/wasm-opt": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.11.1.tgz", - "integrity": "sha512-VqnkNqnZlU5EB64pp1l7hdm3hmQw7Vgqa0KF/KCNO9sIpI6Fk6brDEiX+iCOYrvMuBWDws0NkTOxYEb85XQHHw==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.12.1.tgz", + "integrity": "sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==", "dev": true, "peer": true, "requires": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-buffer": "1.11.1", - "@webassemblyjs/wasm-gen": "1.11.1", - "@webassemblyjs/wasm-parser": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1" } }, "@webassemblyjs/wasm-parser": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.11.1.tgz", - "integrity": "sha512-rrBujw+dJu32gYB7/Lup6UhdkPx9S9SnobZzRVL7VcBH9Bt9bCBLEuX/YXOOtBsOZ4NQrRykKhffRWHvigQvOA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.12.1.tgz", + "integrity": "sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==", "dev": true, "peer": true, "requires": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-api-error": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/ieee754": "1.11.1", - "@webassemblyjs/leb128": "1.11.1", - "@webassemblyjs/utf8": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-api-error": "1.11.6", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/ieee754": "1.11.6", + "@webassemblyjs/leb128": "1.11.6", + "@webassemblyjs/utf8": "1.11.6" } }, "@webassemblyjs/wast-printer": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.11.1.tgz", - "integrity": "sha512-IQboUWM4eKzWW+N/jij2sRatKMh99QEelo3Eb2q0qXkvPRISAj8Qxtmw5itwqK+TTkBuUIE45AxYPToqPtL5gg==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.12.1.tgz", + "integrity": "sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==", "dev": true, "peer": true, "requires": { - "@webassemblyjs/ast": "1.11.1", + "@webassemblyjs/ast": "1.12.1", "@xtuc/long": "4.2.2" } }, @@ -17064,11 +17157,11 @@ "dev": true }, "axios": { - "version": "1.6.1", - "resolved": "https://registry.npmjs.org/axios/-/axios-1.6.1.tgz", - "integrity": "sha512-vfBmhDpKafglh0EldBEbVuoe7DyAavGSLWhuSm5ZSEKQnHhBf0xAAwybbNH1IkrJNGnS/VG4I5yxig1pCEXE4g==", + "version": "1.7.4", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.7.4.tgz", + "integrity": "sha512-DukmaFRnY6AzAALSH4J2M3k6PkaC+MfaAGdEERRWcC9q3/TWQwLpHR8ZRLKTdQ3aBDL64EdluRDjJqKw+BPZEw==", "requires": { - "follow-redirects": "^1.15.0", + "follow-redirects": "^1.15.6", "form-data": "^4.0.0", "proxy-from-env": "^1.1.0" }, @@ -17370,9 +17463,9 @@ } }, "body-parser": { - "version": "1.20.2", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", - "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", + "version": "1.20.3", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", + "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", "requires": { "bytes": "3.1.2", "content-type": "~1.0.5", @@ -17382,7 +17475,7 @@ "http-errors": "2.0.0", "iconv-lite": "0.4.24", "on-finished": "2.4.1", - "qs": "6.11.0", + "qs": "6.13.0", "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" @@ -17400,6 +17493,14 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" + }, + "qs": { + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz", + "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==", + "requires": { + "side-channel": "^1.0.6" + } } } }, @@ -17476,12 +17577,15 @@ "integrity": "sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==" }, "call-bind": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", - "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.7.tgz", + "integrity": "sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==", "requires": { - "function-bind": "^1.1.1", - "get-intrinsic": "^1.0.2" + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "set-function-length": "^1.2.1" } }, "callsites": { @@ -17970,6 +18074,16 @@ "clone": "^1.0.2" } }, + "define-data-property": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", + "integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==", + "requires": { + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "gopd": "^1.0.1" + } + }, "define-properties": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.3.tgz", @@ -18145,9 +18259,9 @@ } }, "enhanced-resolve": { - "version": "5.12.0", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.12.0.tgz", - "integrity": "sha512-QHTXI/sZQmko1cbDoNAa3mJ5qhWUUNAq3vR0/YiD379fWQrcfuoX1+HW2S0MTt7XmoPLapdaDKUtelUSPic7hQ==", + "version": "5.17.1", + "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.17.1.tgz", + "integrity": "sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg==", "dev": true, "peer": true, "requires": { @@ -18201,10 +18315,23 @@ "unbox-primitive": "^1.0.1" } }, + "es-define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.0.tgz", + "integrity": "sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==", + "requires": { + "get-intrinsic": "^1.2.4" + } + }, + "es-errors": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", + "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==" + }, "es-module-lexer": { - "version": "0.9.3", - "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-0.9.3.tgz", - "integrity": "sha512-1HQ2M2sPtxwnvOvT1ZClHyQDiggdNjURWpY2we6aMKCQiUVxTmVs2UYPLIrD84sS+kMdUwfBSylbJPwNnBrnHQ==", + "version": "1.5.4", + "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.5.4.tgz", + "integrity": "sha512-MVNK56NiMrOwitFB7cqDwq0CQutbw+0BvLshJSse0MUNU+y1FC3bUS/AQg7oUng+/wKrrki7JfmwtVHkVfPLlw==", "dev": true, "peer": true }, @@ -18798,36 +18925,36 @@ } }, "express": { - "version": "4.19.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", - "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", + "version": "4.20.0", + "resolved": "https://registry.npmjs.org/express/-/express-4.20.0.tgz", + "integrity": "sha512-pLdae7I6QqShF5PnNTCVn4hI91Dx0Grkn2+IAsMTgMIKuQVte2dN9PeGSSAME2FR8anOhVA62QDIUaWVfEXVLw==", "requires": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.2", + "body-parser": "1.20.3", "content-disposition": "0.5.4", "content-type": "~1.0.4", "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "etag": "~1.8.1", "finalhandler": "1.2.0", "fresh": "0.5.2", "http-errors": "2.0.0", - "merge-descriptors": "1.0.1", + "merge-descriptors": "1.0.3", "methods": "~1.1.2", "on-finished": "2.4.1", "parseurl": "~1.3.3", - "path-to-regexp": "0.1.7", + "path-to-regexp": "0.1.10", "proxy-addr": "~2.0.7", "qs": "6.11.0", "range-parser": "~1.2.1", "safe-buffer": "5.2.1", - "send": "0.18.0", - "serve-static": "1.15.0", + "send": "0.19.0", + "serve-static": "1.16.0", "setprototypeof": "1.2.0", "statuses": "2.0.1", "type-is": "~1.6.18", @@ -18848,6 +18975,11 @@ "ms": "2.0.0" } }, + "encodeurl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", + "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==" + }, "ms": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", @@ -19118,9 +19250,9 @@ "optional": true }, "function-bind": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", - "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", + "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==" }, "functional-red-black-tree": { "version": "1.0.1", @@ -19147,13 +19279,15 @@ "dev": true }, "get-intrinsic": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.1.1.tgz", - "integrity": "sha512-kWZrnVM42QCiEA2Ig1bG8zjoIMOgxWwYCEeNdwY6Tv/cOSeGpcoX4pXHfKUxNKVoArnrEr2e9srnAxxGIraS9Q==", + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.4.tgz", + "integrity": "sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==", "requires": { - "function-bind": "^1.1.1", - "has": "^1.0.3", - "has-symbols": "^1.0.1" + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "hasown": "^2.0.0" } }, "get-package-type": { @@ -19251,10 +19385,18 @@ } } }, + "gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "requires": { + "get-intrinsic": "^1.1.3" + } + }, "graceful-fs": { - "version": "4.2.10", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz", - "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==", + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", "dev": true }, "graphql": { @@ -19344,6 +19486,7 @@ "version": "1.0.3", "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dev": true, "requires": { "function-bind": "^1.1.1" } @@ -19360,10 +19503,23 @@ "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=", "dev": true }, - "has-symbols": { + "has-property-descriptors": { "version": "1.0.2", - "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.2.tgz", - "integrity": "sha512-chXa79rL/UC2KlX17jo3vRGz0azaWEx5tGqZg5pO3NUyEJVB17dMruQlzCCOfUvElghKcm5194+BCRvi2Rv/Gw==" + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz", + "integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==", + "requires": { + "es-define-property": "^1.0.0" + } + }, + "has-proto": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.3.tgz", + "integrity": "sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==" + }, + "has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==" }, "has-tostringtag": { "version": "1.0.0", @@ -19374,6 +19530,14 @@ "has-symbols": "^1.0.2" } }, + "hasown": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", + "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", + "requires": { + "function-bind": "^1.1.2" + } + }, "hexoid": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/hexoid/-/hexoid-1.0.0.tgz", @@ -21805,9 +21969,9 @@ "integrity": "sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g=" }, "merge-descriptors": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", - "integrity": "sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E=" + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", + "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==" }, "merge-stream": { "version": "2.0.0", @@ -22047,12 +22211,12 @@ "dev": true }, "notifications-node-client": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/notifications-node-client/-/notifications-node-client-8.0.0.tgz", - "integrity": "sha512-65BxorFYVFOpJ9c2lud/4Ju+Bfn3L/vkih+FuzMhBw1wcOPjwgu4doVH6xO91fHYiAi/0uIx0Mc+NorXeANMHw==", + "version": "8.2.1", + "resolved": "https://registry.npmjs.org/notifications-node-client/-/notifications-node-client-8.2.1.tgz", + "integrity": "sha512-wyZh/NbjN8S2uQX18utYtCyC726BBaGeTc4HeUpdhZv5sYKuaQY94N31v9syh8SzVgehyMzW37y08EePmi+k3Q==", "requires": { - "axios": "^1.6.1", - "jsonwebtoken": "^9.0.0" + "axios": "^1.7.2", + "jsonwebtoken": "^9.0.2" } }, "npm-run-path": { @@ -22076,9 +22240,9 @@ "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=" }, "object-inspect": { - "version": "1.11.0", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.11.0.tgz", - "integrity": "sha512-jp7ikS6Sd3GxQfZJPyH3cjcbJF6GZPClgdV+EFygjFLQ5FmW/dRUnTd9PQ9k0JhoNDabWFbpF1yCdSWCC6gexg==" + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.2.tgz", + "integrity": "sha512-IRZSRuzJiynemAXPYtPe5BoI/RESNYR7TYm50MC5Mqbd3Jmw5y790sErYw3V6SryFJD64b74qQQs9wn5Bg/k3g==" }, "object-keys": { "version": "1.1.1", @@ -22347,9 +22511,9 @@ "dev": true }, "path-to-regexp": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", - "integrity": "sha1-32BBeABfUi8V60SQ5yR6G/qmf4w=" + "version": "0.1.10", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.10.tgz", + "integrity": "sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w==" }, "path-type": { "version": "4.0.0", @@ -22878,9 +23042,9 @@ } }, "schema-utils": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.1.1.tgz", - "integrity": "sha512-Y5PQxS4ITlC+EahLuXaY86TXfR7Dc5lw294alXOq86JAHCihAIZfqv8nNCWvaEJvaC51uN9hbLGeV0cFBdH+Fw==", + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.3.0.tgz", + "integrity": "sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==", "dev": true, "peer": true, "requires": { @@ -22896,9 +23060,9 @@ "dev": true }, "send": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", - "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "version": "0.19.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", + "integrity": "sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==", "requires": { "debug": "2.6.9", "depd": "2.0.0", @@ -22933,9 +23097,9 @@ } }, "serialize-javascript": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.0.tgz", - "integrity": "sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag==", + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz", + "integrity": "sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==", "dev": true, "peer": true, "requires": { @@ -22943,14 +23107,64 @@ } }, "serve-static": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.15.0.tgz", - "integrity": "sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==", + "version": "1.16.0", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.16.0.tgz", + "integrity": "sha512-pDLK8zwl2eKaYrs8mrPZBJua4hMplRWJ1tIFksVC3FtBEBnl8dxgeHtsaMS8DhS9i4fLObaon6ABoc4/hQGdPA==", "requires": { "encodeurl": "~1.0.2", "escape-html": "~1.0.3", "parseurl": "~1.3.3", "send": "0.18.0" + }, + "dependencies": { + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "requires": { + "ms": "2.0.0" + }, + "dependencies": { + "ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==" + } + } + }, + "send": { + "version": "0.18.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", + "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "requires": { + "debug": "2.6.9", + "depd": "2.0.0", + "destroy": "1.2.0", + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "etag": "~1.8.1", + "fresh": "0.5.2", + "http-errors": "2.0.0", + "mime": "1.6.0", + "ms": "2.1.3", + "on-finished": "2.4.1", + "range-parser": "~1.2.1", + "statuses": "2.0.1" + } + } + } + }, + "set-function-length": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", + "integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==", + "requires": { + "define-data-property": "^1.1.4", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.2" } }, "setprototypeof": { @@ -22992,13 +23206,14 @@ "dev": true }, "side-channel": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", - "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.6.tgz", + "integrity": "sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==", "requires": { - "call-bind": "^1.0.0", - "get-intrinsic": "^1.0.2", - "object-inspect": "^1.9.0" + "call-bind": "^1.0.7", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.4", + "object-inspect": "^1.13.1" } }, "signal-exit": { @@ -23360,22 +23575,22 @@ } }, "terser": { - "version": "5.14.2", - "resolved": "https://registry.npmjs.org/terser/-/terser-5.14.2.tgz", - "integrity": "sha512-oL0rGeM/WFQCUd0y2QrWxYnq7tfSuKBiqTjRPWrRgB46WD/kiwHwF8T23z78H6Q6kGCuuHcPB+KULHRdxvVGQA==", + "version": "5.31.6", + "resolved": "https://registry.npmjs.org/terser/-/terser-5.31.6.tgz", + "integrity": "sha512-PQ4DAriWzKj+qgehQ7LK5bQqCFNMmlhjR2PFFLuqGCpuCAauxemVBWwWOxo3UIwWQx8+Pr61Df++r76wDmkQBg==", "dev": true, "peer": true, "requires": { - "@jridgewell/source-map": "^0.3.2", - "acorn": "^8.5.0", + "@jridgewell/source-map": "^0.3.3", + "acorn": "^8.8.2", "commander": "^2.20.0", "source-map-support": "~0.5.20" }, "dependencies": { "acorn": { - "version": "8.7.1", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.7.1.tgz", - "integrity": "sha512-Xx54uLJQZ19lKygFXOWsscKUbsBZW0CPykPhVQdhIeIwrbPmJzqeASDInc8nKBnp/JT6igTs82qPXz069H8I/A==", + "version": "8.12.1", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.12.1.tgz", + "integrity": "sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg==", "dev": true, "peer": true }, @@ -23389,37 +23604,17 @@ } }, "terser-webpack-plugin": { - "version": "5.2.4", - "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.2.4.tgz", - "integrity": "sha512-E2CkNMN+1cho04YpdANyRrn8CyN4yMy+WdFKZIySFZrGXZxJwJP6PMNGGc/Mcr6qygQHUUqRxnAPmi0M9f00XA==", + "version": "5.3.10", + "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.10.tgz", + "integrity": "sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==", "dev": true, "peer": true, "requires": { - "jest-worker": "^27.0.6", - "p-limit": "^3.1.0", + "@jridgewell/trace-mapping": "^0.3.20", + "jest-worker": "^27.4.5", "schema-utils": "^3.1.1", - "serialize-javascript": "^6.0.0", - "source-map": "^0.6.1", - "terser": "^5.7.2" - }, - "dependencies": { - "p-limit": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", - "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", - "dev": true, - "peer": true, - "requires": { - "yocto-queue": "^0.1.0" - } - }, - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true, - "peer": true - } + "serialize-javascript": "^6.0.1", + "terser": "^5.26.0" } }, "test-exclude": { @@ -23821,9 +24016,9 @@ } }, "watchpack": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.0.tgz", - "integrity": "sha512-Lcvm7MGST/4fup+ifyKi2hjyIAwcdI4HRgtvTpIUxBRhB+RFtUh8XtDOxUfctVCnhVi+QQj49i91OyvzkJl6cg==", + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.2.tgz", + "integrity": "sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==", "dev": true, "peer": true, "requires": { @@ -23847,49 +24042,48 @@ "dev": true }, "webpack": { - "version": "5.76.1", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.76.1.tgz", - "integrity": "sha512-4+YIK4Abzv8172/SGqObnUjaIHjLEuUasz9EwQj/9xmPPkYJy2Mh03Q/lJfSD3YLzbxy5FeTq5Uw0323Oh6SJQ==", + "version": "5.94.0", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.94.0.tgz", + "integrity": "sha512-KcsGn50VT+06JH/iunZJedYGUJS5FGjow8wb9c0v5n1Om8O1g4L6LjtfxwlXIATopoQu+vOXXa7gYisWxCoPyg==", "dev": true, "peer": true, "requires": { - "@types/eslint-scope": "^3.7.3", - "@types/estree": "^0.0.51", - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/wasm-edit": "1.11.1", - "@webassemblyjs/wasm-parser": "1.11.1", + "@types/estree": "^1.0.5", + "@webassemblyjs/ast": "^1.12.1", + "@webassemblyjs/wasm-edit": "^1.12.1", + "@webassemblyjs/wasm-parser": "^1.12.1", "acorn": "^8.7.1", - "acorn-import-assertions": "^1.7.6", - "browserslist": "^4.14.5", + "acorn-import-attributes": "^1.9.5", + "browserslist": "^4.21.10", "chrome-trace-event": "^1.0.2", - "enhanced-resolve": "^5.10.0", - "es-module-lexer": "^0.9.0", + "enhanced-resolve": "^5.17.1", + "es-module-lexer": "^1.2.1", "eslint-scope": "5.1.1", "events": "^3.2.0", "glob-to-regexp": "^0.4.1", - "graceful-fs": "^4.2.9", + "graceful-fs": "^4.2.11", "json-parse-even-better-errors": "^2.3.1", "loader-runner": "^4.2.0", "mime-types": "^2.1.27", "neo-async": "^2.6.2", - "schema-utils": "^3.1.0", + "schema-utils": "^3.2.0", "tapable": "^2.1.1", - "terser-webpack-plugin": "^5.1.3", - "watchpack": "^2.4.0", + "terser-webpack-plugin": "^5.3.10", + "watchpack": "^2.4.1", "webpack-sources": "^3.2.3" }, "dependencies": { "acorn": { - "version": "8.8.2", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz", - "integrity": "sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw==", + "version": "8.12.1", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.12.1.tgz", + "integrity": "sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg==", "dev": true, "peer": true }, - "acorn-import-assertions": { - "version": "1.7.6", - "resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.7.6.tgz", - "integrity": "sha512-FlVvVFA1TX6l3lp8VjDnYYq7R1nyW6x3svAt4nDgrWQ9SBaSh9CnbwgSUTasgfNfOG5HlM1ehugCvM+hjo56LA==", + "acorn-import-attributes": { + "version": "1.9.5", + "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz", + "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==", "dev": true, "peer": true, "requires": {} @@ -24100,13 +24294,6 @@ "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", "dev": true - }, - "yocto-queue": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", - "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", - "dev": true, - "peer": true } } } diff --git a/api/package.json b/api/package.json index 34defc3c71..eaddeeb849 100644 --- a/api/package.json +++ b/api/package.json @@ -33,7 +33,7 @@ "cors": "^2.8.5", "dataloader": "^2.0.0", "dotenv-safe": "^8.2.0", - "express": "^4.19.2", + "express": "^4.20.0", "express-request-language": "^1.1.15", "graphql": "^16.8.1", "graphql-depth-limit": "^1.1.0", @@ -49,7 +49,7 @@ "moment": "^2.29.4", "ms": "^2.1.3", "nats": "^2.18.0", - "notifications-node-client": "^8.0.0", + "notifications-node-client": "^8.2.1", "url-slug": "^3.0.2", "uuid": "^8.3.2", "validator": "^13.7.0" diff --git a/api/src/__tests__/server.test.js b/api/src/__tests__/server.test.js index 84b94b08a9..94f16e71d2 100644 --- a/api/src/__tests__/server.test.js +++ b/api/src/__tests__/server.test.js @@ -1,6 +1,7 @@ import request from 'supertest' import { Server } from '../server' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../testUtilities' import dbschema from '../../database.json' const { diff --git a/api/src/additional-findings/loaders/load-additional-findings-by-domain-id.js b/api/src/additional-findings/loaders/load-additional-findings-by-domain-id.js index 6b67ae68b7..9e99303ee0 100644 --- a/api/src/additional-findings/loaders/load-additional-findings-by-domain-id.js +++ b/api/src/additional-findings/loaders/load-additional-findings-by-domain-id.js @@ -14,6 +14,7 @@ export const loadAdditionalFindingsByDomainId = WITH additionalFindings, domains FOR finding IN additionalFindings FILTER finding.domain == ${domainId} + LIMIT 1 RETURN finding ` } catch (err) { diff --git a/api/src/affiliation/loaders/__tests__/load-affiliation-by-key.test.js b/api/src/affiliation/loaders/__tests__/load-affiliation-by-key.test.js index cb0b746947..5575ba7b5d 100644 --- a/api/src/affiliation/loaders/__tests__/load-affiliation-by-key.test.js +++ b/api/src/affiliation/loaders/__tests__/load-affiliation-by-key.test.js @@ -1,12 +1,13 @@ -import {ensure, dbNameFromFile} from 'arango-tools' -import {loadAffiliationByKey} from '..' -import {setupI18n} from '@lingui/core' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' +import { loadAffiliationByKey } from '..' +import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' import frenchMessages from '../../../locale/fr/messages' import dbschema from '../../../../database.json' -const {DB_PASS: rootPass, DB_URL: url} = process.env +const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given a loadAffiliationByKey dataloader', () => { let i18n @@ -24,7 +25,7 @@ describe('given a loadAffiliationByKey dataloader', () => { let query, drop, truncate, collections, orgOne, orgTwo, affOne, user beforeAll(async () => { - ;({query, drop, truncate, collections} = await ensure({ + ;({ query, drop, truncate, collections } = await ensure({ variables: { dbname: dbNameFromFile(__filename), username: 'root', @@ -125,7 +126,7 @@ describe('given a loadAffiliationByKey dataloader', () => { ` const expectedAffiliation = await expectedCursor.next() - const loader = loadAffiliationByKey({query, i18n}) + const loader = loadAffiliationByKey({ query, i18n }) const affiliation = await loader.load(expectedAffiliation._key) expect(affiliation).toEqual(expectedAffiliation) @@ -148,7 +149,7 @@ describe('given a loadAffiliationByKey dataloader', () => { expectedAffiliations.push(tempAff) } - const loader = loadAffiliationByKey({query, i18n}) + const loader = loadAffiliationByKey({ query, i18n }) const affiliations = await loader.loadMany(affiliationIds) expect(affiliations).toEqual(expectedAffiliations) }) @@ -160,8 +161,8 @@ describe('given a loadAffiliationByKey dataloader', () => { i18n = setupI18n({ locale: 'en', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -172,9 +173,7 @@ describe('given a loadAffiliationByKey dataloader', () => { }) describe('database error is raised', () => { it('throws an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadAffiliationByKey({ query: mockedQuery, userKey: '1234', @@ -184,9 +183,7 @@ describe('given a loadAffiliationByKey dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error('Unable to find user affiliation(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to find user affiliation(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -211,9 +208,7 @@ describe('given a loadAffiliationByKey dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error('Unable to find user affiliation(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to find user affiliation(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -227,8 +222,8 @@ describe('given a loadAffiliationByKey dataloader', () => { i18n = setupI18n({ locale: 'fr', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -239,9 +234,7 @@ describe('given a loadAffiliationByKey dataloader', () => { }) describe('database error is raised', () => { it('throws an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadAffiliationByKey({ query: mockedQuery, userKey: '1234', @@ -252,9 +245,7 @@ describe('given a loadAffiliationByKey dataloader', () => { await loader.load('1') } catch (err) { expect(err).toEqual( - new Error( - `Impossible de trouver l'affiliation de l'utilisateur (s). Veuillez réessayer.`, - ), + new Error(`Impossible de trouver l'affiliation de l'utilisateur (s). Veuillez réessayer.`), ) } @@ -281,9 +272,7 @@ describe('given a loadAffiliationByKey dataloader', () => { await loader.load('1') } catch (err) { expect(err).toEqual( - new Error( - `Impossible de trouver l'affiliation de l'utilisateur (s). Veuillez réessayer.`, - ), + new Error(`Impossible de trouver l'affiliation de l'utilisateur (s). Veuillez réessayer.`), ) } diff --git a/api/src/affiliation/loaders/__tests__/load-affiliation-connections-by-org-id.test.js b/api/src/affiliation/loaders/__tests__/load-affiliation-connections-by-org-id.test.js index cc018b66d8..c1e72bc048 100644 --- a/api/src/affiliation/loaders/__tests__/load-affiliation-connections-by-org-id.test.js +++ b/api/src/affiliation/loaders/__tests__/load-affiliation-connections-by-org-id.test.js @@ -1,18 +1,16 @@ -import {stringify} from 'jest-matcher-utils' -import {ensure, dbNameFromFile} from 'arango-tools' -import {toGlobalId} from 'graphql-relay' -import {setupI18n} from '@lingui/core' +import { stringify } from 'jest-matcher-utils' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' +import { toGlobalId } from 'graphql-relay' +import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' import frenchMessages from '../../../locale/fr/messages' -import {cleanseInput} from '../../../validators' -import { - loadAffiliationConnectionsByOrgId, - loadAffiliationByKey, -} from '../index' +import { cleanseInput } from '../../../validators' +import { loadAffiliationConnectionsByOrgId, loadAffiliationByKey } from '../index' import dbschema from '../../../../database.json' -const {DB_PASS: rootPass, DB_URL: url} = process.env +const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the load affiliations by org id function', () => { let query, drop, truncate, collections, user, org, userTwo, i18n @@ -30,7 +28,7 @@ describe('given the load affiliations by org id function', () => { describe('given a successful load', () => { beforeAll(async () => { - ;({query, drop, truncate, collections} = await ensure({ + ;({ query, drop, truncate, collections } = await ensure({ variables: { dbname: dbNameFromFile(__filename), username: 'root', @@ -122,11 +120,8 @@ describe('given the load affiliations by org id function', () => { i18n, }) - const affLoader = loadAffiliationByKey({query}) - const expectedAffiliations = await affLoader.loadMany([ - affOne._key, - affTwo._key, - ]) + const affLoader = loadAffiliationByKey({ query }) + const expectedAffiliations = await affLoader.loadMany([affOne._key, affTwo._key]) expectedAffiliations[0].id = expectedAffiliations[0]._key expectedAffiliations[1].id = expectedAffiliations[1]._key @@ -153,14 +148,8 @@ describe('given the load affiliations by org id function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'affiliation', - expectedAffiliations[1]._key, - ), - endCursor: toGlobalId( - 'affiliation', - expectedAffiliations[1]._key, - ), + startCursor: toGlobalId('affiliation', expectedAffiliations[1]._key), + endCursor: toGlobalId('affiliation', expectedAffiliations[1]._key), }, } @@ -176,11 +165,8 @@ describe('given the load affiliations by org id function', () => { i18n, }) - const affLoader = loadAffiliationByKey({query}) - const expectedAffiliations = await affLoader.loadMany([ - affOne._key, - affTwo._key, - ]) + const affLoader = loadAffiliationByKey({ query }) + const expectedAffiliations = await affLoader.loadMany([affOne._key, affTwo._key]) expectedAffiliations[0].id = expectedAffiliations[0]._key expectedAffiliations[1].id = expectedAffiliations[1]._key @@ -197,10 +183,7 @@ describe('given the load affiliations by org id function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + cursor: toGlobalId('affiliation', expectedAffiliations[0]._key), node: { ...expectedAffiliations[0], }, @@ -210,14 +193,8 @@ describe('given the load affiliations by org id function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), - endCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + startCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), + endCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), }, } @@ -233,11 +210,8 @@ describe('given the load affiliations by org id function', () => { i18n, }) - const affLoader = loadAffiliationByKey({query}) - const expectedAffiliations = await affLoader.loadMany([ - affOne._key, - affTwo._key, - ]) + const affLoader = loadAffiliationByKey({ query }) + const expectedAffiliations = await affLoader.loadMany([affOne._key, affTwo._key]) expectedAffiliations[0].id = expectedAffiliations[0]._key expectedAffiliations[1].id = expectedAffiliations[1]._key @@ -253,10 +227,7 @@ describe('given the load affiliations by org id function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + cursor: toGlobalId('affiliation', expectedAffiliations[0]._key), node: { ...expectedAffiliations[0], }, @@ -266,14 +237,8 @@ describe('given the load affiliations by org id function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), - endCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + startCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), + endCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), }, } @@ -289,11 +254,8 @@ describe('given the load affiliations by org id function', () => { i18n, }) - const affLoader = loadAffiliationByKey({query}) - const expectedAffiliations = await affLoader.loadMany([ - affOne._key, - affTwo._key, - ]) + const affLoader = loadAffiliationByKey({ query }) + const expectedAffiliations = await affLoader.loadMany([affOne._key, affTwo._key]) expectedAffiliations[0].id = expectedAffiliations[0]._key expectedAffiliations[1].id = expectedAffiliations[1]._key @@ -309,10 +271,7 @@ describe('given the load affiliations by org id function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'affiliation', - expectedAffiliations[1]._key, - ), + cursor: toGlobalId('affiliation', expectedAffiliations[1]._key), node: { ...expectedAffiliations[1], }, @@ -322,14 +281,8 @@ describe('given the load affiliations by org id function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'affiliation', - expectedAffiliations[1]._key, - ), - endCursor: toGlobalId( - 'affiliation', - expectedAffiliations[1]._key, - ), + startCursor: toGlobalId('affiliation', expectedAffiliations[1]._key), + endCursor: toGlobalId('affiliation', expectedAffiliations[1]._key), }, } @@ -355,11 +308,8 @@ describe('given the load affiliations by org id function', () => { i18n, }) - const affLoader = loadAffiliationByKey({query}) - const expectedAffiliations = await affLoader.loadMany([ - affOne._key, - affTwo._key, - ]) + const affLoader = loadAffiliationByKey({ query }) + const expectedAffiliations = await affLoader.loadMany([affOne._key, affTwo._key]) expectedAffiliations[0].id = expectedAffiliations[0]._key expectedAffiliations[1].id = expectedAffiliations[1]._key @@ -376,27 +326,18 @@ describe('given the load affiliations by org id function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + cursor: toGlobalId('affiliation', expectedAffiliations[0]._key), node: { ...expectedAffiliations[0], }, }, ], - totalCount: 2, + totalCount: 1, pageInfo: { - hasNextPage: true, + hasNextPage: false, hasPreviousPage: false, - startCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), - endCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + startCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), + endCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), }, } @@ -412,11 +353,8 @@ describe('given the load affiliations by org id function', () => { i18n, }) - const affLoader = loadAffiliationByKey({query}) - const expectedAffiliations = await affLoader.loadMany([ - affOne._key, - affTwo._key, - ]) + const affLoader = loadAffiliationByKey({ query }) + const expectedAffiliations = await affLoader.loadMany([affOne._key, affTwo._key]) expectedAffiliations[0].id = expectedAffiliations[0]._key expectedAffiliations[1].id = expectedAffiliations[1]._key @@ -433,27 +371,18 @@ describe('given the load affiliations by org id function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + cursor: toGlobalId('affiliation', expectedAffiliations[0]._key), node: { ...expectedAffiliations[0], }, }, ], - totalCount: 2, + totalCount: 1, pageInfo: { - hasNextPage: true, + hasNextPage: false, hasPreviousPage: false, - startCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), - endCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + startCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), + endCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), }, } @@ -669,8 +598,8 @@ describe('given the load affiliations by org id function', () => { i18n = setupI18n({ locale: 'en', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en'], messages: { @@ -693,12 +622,10 @@ describe('given the load affiliations by org id function', () => { last: 1, } try { - await affiliationLoader({orgId: org._id, ...connectionArgs}) + await affiliationLoader({ orgId: org._id, ...connectionArgs }) } catch (err) { expect(err).toEqual( - new Error( - 'Passing both `first` and `last` to paginate the `Affiliation` connection is not supported.', - ), + new Error('Passing both `first` and `last` to paginate the `Affiliation` connection is not supported.'), ) } @@ -755,11 +682,7 @@ describe('given the load affiliations by org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` on the `Affiliation` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`first` on the `Affiliation` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` set below zero for: loadAffiliationConnectionsByOrgId.`, @@ -785,11 +708,7 @@ describe('given the load affiliations by org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` on the `Affiliation` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`last` on the `Affiliation` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`last\` set below zero for: loadAffiliationConnectionsByOrgId.`, @@ -862,9 +781,7 @@ describe('given the load affiliations by org id function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const affiliationLoader = loadAffiliationConnectionsByOrgId({ query, userKey: user._key, @@ -881,11 +798,7 @@ describe('given the load affiliations by org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -897,9 +810,7 @@ describe('given the load affiliations by org id function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const affiliationLoader = loadAffiliationConnectionsByOrgId({ query, userKey: user._key, @@ -916,11 +827,7 @@ describe('given the load affiliations by org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -935,11 +842,7 @@ describe('given the load affiliations by org id function', () => { describe('given a database error', () => { describe('while querying affiliations', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue( - new Error('Unable to query organizations. Please try again.'), - ) + const query = jest.fn().mockRejectedValue(new Error('Unable to query organizations. Please try again.')) const affiliationLoader = loadAffiliationConnectionsByOrgId({ query, @@ -952,11 +855,9 @@ describe('given the load affiliations by org id function', () => { first: 5, } try { - await affiliationLoader({orgId: org._id, ...connectionArgs}) + await affiliationLoader({ orgId: org._id, ...connectionArgs }) } catch (err) { - expect(err).toEqual( - new Error('Unable to query affiliation(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to query affiliation(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -986,11 +887,9 @@ describe('given the load affiliations by org id function', () => { first: 5, } try { - await affiliationLoader({orgId: org._id, ...connectionArgs}) + await affiliationLoader({ orgId: org._id, ...connectionArgs }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load affiliation(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load affiliation(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -1005,8 +904,8 @@ describe('given the load affiliations by org id function', () => { i18n = setupI18n({ locale: 'fr', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['fr'], messages: { @@ -1029,7 +928,7 @@ describe('given the load affiliations by org id function', () => { last: 1, } try { - await affiliationLoader({orgId: org._id, ...connectionArgs}) + await affiliationLoader({ orgId: org._id, ...connectionArgs }) } catch (err) { expect(err).toEqual( new Error( @@ -1092,9 +991,7 @@ describe('given the load affiliations by org id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` sur la connexion \`Affiliation\` ne peut être inférieur à zéro.`, - ), + new Error(`\`first\` sur la connexion \`Affiliation\` ne peut être inférieur à zéro.`), ) } expect(consoleOutput).toEqual([ @@ -1121,11 +1018,7 @@ describe('given the load affiliations by org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` sur la connexion \`Affiliation\` ne peut être inférieur à zéro.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` sur la connexion \`Affiliation\` ne peut être inférieur à zéro.`)) } expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`last\` set below zero for: loadAffiliationConnectionsByOrgId.`, @@ -1198,9 +1091,7 @@ describe('given the load affiliations by org id function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const affiliationLoader = loadAffiliationConnectionsByOrgId({ query, userKey: user._key, @@ -1218,9 +1109,7 @@ describe('given the load affiliations by org id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -1233,9 +1122,7 @@ describe('given the load affiliations by org id function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const affiliationLoader = loadAffiliationConnectionsByOrgId({ query, userKey: user._key, @@ -1253,9 +1140,7 @@ describe('given the load affiliations by org id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -1271,11 +1156,7 @@ describe('given the load affiliations by org id function', () => { describe('given a database error', () => { describe('while querying affiliations', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue( - new Error('Unable to query organizations. Please try again.'), - ) + const query = jest.fn().mockRejectedValue(new Error('Unable to query organizations. Please try again.')) const affiliationLoader = loadAffiliationConnectionsByOrgId({ query, @@ -1288,13 +1169,9 @@ describe('given the load affiliations by org id function', () => { first: 5, } try { - await affiliationLoader({orgId: org._id, ...connectionArgs}) + await affiliationLoader({ orgId: org._id, ...connectionArgs }) } catch (err) { - expect(err).toEqual( - new Error( - `Impossible de demander l'affiliation (s). Veuillez réessayer.`, - ), - ) + expect(err).toEqual(new Error(`Impossible de demander l'affiliation (s). Veuillez réessayer.`)) } expect(consoleOutput).toEqual([ @@ -1324,13 +1201,9 @@ describe('given the load affiliations by org id function', () => { first: 5, } try { - await affiliationLoader({orgId: org._id, ...connectionArgs}) + await affiliationLoader({ orgId: org._id, ...connectionArgs }) } catch (err) { - expect(err).toEqual( - new Error( - `Impossible de charger l'affiliation (s). Veuillez réessayer.`, - ), - ) + expect(err).toEqual(new Error(`Impossible de charger l'affiliation (s). Veuillez réessayer.`)) } expect(consoleOutput).toEqual([ diff --git a/api/src/affiliation/loaders/__tests__/load-affiliation-connections-by-user-id.test.js b/api/src/affiliation/loaders/__tests__/load-affiliation-connections-by-user-id.test.js index 9c967acba3..e2c3baeb47 100644 --- a/api/src/affiliation/loaders/__tests__/load-affiliation-connections-by-user-id.test.js +++ b/api/src/affiliation/loaders/__tests__/load-affiliation-connections-by-user-id.test.js @@ -1,15 +1,16 @@ -import {stringify} from 'jest-matcher-utils' -import {ensure, dbNameFromFile} from 'arango-tools' -import {toGlobalId} from 'graphql-relay' -import {setupI18n} from '@lingui/core' +import { stringify } from 'jest-matcher-utils' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' +import { toGlobalId } from 'graphql-relay' +import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' import frenchMessages from '../../../locale/fr/messages' -import {cleanseInput} from '../../../validators' -import {loadAffiliationConnectionsByUserId, loadAffiliationByKey} from '..' +import { cleanseInput } from '../../../validators' +import { loadAffiliationConnectionsByUserId, loadAffiliationByKey } from '..' import dbschema from '../../../../database.json' -const {DB_PASS: rootPass, DB_URL: url} = process.env +const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the load affiliations by user id function', () => { let query, drop, truncate, collections, user, orgOne, orgTwo, i18n @@ -30,7 +31,7 @@ describe('given the load affiliations by user id function', () => { describe('given there are user affiliations to be returned', () => { let affOne, affTwo beforeAll(async () => { - ;({query, drop, truncate, collections} = await ensure({ + ;({ query, drop, truncate, collections } = await ensure({ variables: { dbname: dbNameFromFile(__filename), username: 'root', @@ -126,11 +127,8 @@ describe('given the load affiliations by user id function', () => { i18n, }) - const affLoader = loadAffiliationByKey({query}) - const expectedAffiliations = await affLoader.loadMany([ - affOne._key, - affTwo._key, - ]) + const affLoader = loadAffiliationByKey({ query }) + const expectedAffiliations = await affLoader.loadMany([affOne._key, affTwo._key]) expectedAffiliations[0].id = expectedAffiliations[0]._key expectedAffiliations[1].id = expectedAffiliations[1]._key @@ -147,10 +145,7 @@ describe('given the load affiliations by user id function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'affiliation', - expectedAffiliations[1]._key, - ), + cursor: toGlobalId('affiliation', expectedAffiliations[1]._key), node: { ...expectedAffiliations[1], }, @@ -160,14 +155,8 @@ describe('given the load affiliations by user id function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'affiliation', - expectedAffiliations[1]._key, - ), - endCursor: toGlobalId( - 'affiliation', - expectedAffiliations[1]._key, - ), + startCursor: toGlobalId('affiliation', expectedAffiliations[1]._key), + endCursor: toGlobalId('affiliation', expectedAffiliations[1]._key), }, } @@ -203,10 +192,7 @@ describe('given the load affiliations by user id function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + cursor: toGlobalId('affiliation', expectedAffiliations[0]._key), node: { ...expectedAffiliations[0], }, @@ -216,14 +202,8 @@ describe('given the load affiliations by user id function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), - endCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + startCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), + endCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), }, } @@ -258,10 +238,7 @@ describe('given the load affiliations by user id function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + cursor: toGlobalId('affiliation', expectedAffiliations[0]._key), node: { ...expectedAffiliations[0], }, @@ -271,14 +248,8 @@ describe('given the load affiliations by user id function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), - endCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + startCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), + endCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), }, } @@ -313,10 +284,7 @@ describe('given the load affiliations by user id function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'affiliation', - expectedAffiliations[1]._key, - ), + cursor: toGlobalId('affiliation', expectedAffiliations[1]._key), node: { ...expectedAffiliations[1], }, @@ -326,14 +294,8 @@ describe('given the load affiliations by user id function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'affiliation', - expectedAffiliations[1]._key, - ), - endCursor: toGlobalId( - 'affiliation', - expectedAffiliations[1]._key, - ), + startCursor: toGlobalId('affiliation', expectedAffiliations[1]._key), + endCursor: toGlobalId('affiliation', expectedAffiliations[1]._key), }, } @@ -380,10 +342,7 @@ describe('given the load affiliations by user id function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + cursor: toGlobalId('affiliation', expectedAffiliations[0]._key), node: { ...expectedAffiliations[0], }, @@ -393,14 +352,8 @@ describe('given the load affiliations by user id function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), - endCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + startCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), + endCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), }, } @@ -436,10 +389,7 @@ describe('given the load affiliations by user id function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + cursor: toGlobalId('affiliation', expectedAffiliations[0]._key), node: { ...expectedAffiliations[0], }, @@ -449,14 +399,8 @@ describe('given the load affiliations by user id function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), - endCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + startCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), + endCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), }, } @@ -494,10 +438,7 @@ describe('given the load affiliations by user id function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + cursor: toGlobalId('affiliation', expectedAffiliations[0]._key), node: { ...expectedAffiliations[0], }, @@ -507,14 +448,8 @@ describe('given the load affiliations by user id function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), - endCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + startCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), + endCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), }, } @@ -550,10 +485,7 @@ describe('given the load affiliations by user id function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + cursor: toGlobalId('affiliation', expectedAffiliations[0]._key), node: { ...expectedAffiliations[0], }, @@ -563,14 +495,8 @@ describe('given the load affiliations by user id function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), - endCursor: toGlobalId( - 'affiliation', - expectedAffiliations[0]._key, - ), + startCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), + endCursor: toGlobalId('affiliation', expectedAffiliations[0]._key), }, } @@ -580,16 +506,7 @@ describe('given the load affiliations by user id function', () => { }) }) describe('using orderBy field', () => { - let affOne, - affTwo, - affThree, - domainOne, - domainTwo, - domainThree, - orgOne, - orgTwo, - orgThree, - userOne + let affOne, affTwo, affThree, domainOne, domainTwo, domainThree, orgOne, orgTwo, orgThree, userOne beforeEach(async () => { await truncate() userOne = await collections.users.save({ @@ -1300,11 +1217,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -1352,11 +1267,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_PROVINCE', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -1402,11 +1315,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -1454,11 +1365,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_CITY', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -1504,11 +1413,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -1556,11 +1463,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_VERIFIED', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -1606,11 +1511,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -1658,11 +1561,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_SUMMARY_MAIL_PASS', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -1708,11 +1609,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -1760,11 +1659,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_SUMMARY_MAIL_FAIL', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -1810,11 +1707,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -1862,11 +1757,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_SUMMARY_MAIL_TOTAL', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -1912,11 +1805,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -1964,11 +1855,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_SUMMARY_WEB_PASS', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2014,11 +1903,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2066,11 +1953,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_SUMMARY_WEB_FAIL', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2116,11 +2001,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2168,11 +2051,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_SUMMARY_WEB_TOTAL', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2218,11 +2099,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2270,11 +2149,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_DOMAIN_COUNT', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2320,11 +2197,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2374,11 +2249,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_ACRONYM', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2424,11 +2297,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2476,11 +2347,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_NAME', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2526,11 +2395,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2578,11 +2445,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_SLUG', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2628,11 +2493,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2680,11 +2543,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_ZONE', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2730,11 +2591,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2782,11 +2641,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_SECTOR', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2832,11 +2689,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2884,11 +2739,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_COUNTRY', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2934,11 +2787,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -2986,11 +2837,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_PROVINCE', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -3036,11 +2885,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -3088,11 +2935,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_CITY', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -3138,11 +2983,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -3190,11 +3033,9 @@ describe('given the load affiliations by user id function', () => { describe('ordering by ORG_VERIFIED', () => { describe('direction is set to ASC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -3240,11 +3081,9 @@ describe('given the load affiliations by user id function', () => { }) describe('direction is set to DESC', () => { it('returns affiliation', async () => { - const affiliationLoader = loadAffiliationByKey({query}) + const affiliationLoader = loadAffiliationByKey({ query }) - const expectedAffiliation = await affiliationLoader.load( - affTwo._key, - ) + const expectedAffiliation = await affiliationLoader.load(affTwo._key) const connectionLoader = loadAffiliationConnectionsByUserId({ query, @@ -4019,8 +3858,8 @@ describe('given the load affiliations by user id function', () => { i18n = setupI18n({ locale: 'en', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en'], messages: { @@ -4050,9 +3889,7 @@ describe('given the load affiliations by user id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - 'Passing both `first` and `last` to paginate the `Affiliation` connection is not supported.', - ), + new Error('Passing both `first` and `last` to paginate the `Affiliation` connection is not supported.'), ) } @@ -4111,11 +3948,7 @@ describe('given the load affiliations by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` on the `Affiliation` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`first` on the `Affiliation` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` set below zero for: loadAffiliationConnectionsByUserId.`, @@ -4142,11 +3975,7 @@ describe('given the load affiliations by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` on the `Affiliation` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`last` on the `Affiliation` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`last\` set below zero for: loadAffiliationConnectionsByUserId.`, @@ -4221,9 +4050,7 @@ describe('given the load affiliations by user id function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadAffiliationConnectionsByUserId({ query, language: 'en', @@ -4241,11 +4068,7 @@ describe('given the load affiliations by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -4257,9 +4080,7 @@ describe('given the load affiliations by user id function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadAffiliationConnectionsByUserId({ query, language: 'en', @@ -4277,11 +4098,7 @@ describe('given the load affiliations by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -4296,11 +4113,7 @@ describe('given the load affiliations by user id function', () => { describe('given a database error', () => { describe('while querying domains', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue( - new Error('Unable to query organizations. Please try again.'), - ) + const query = jest.fn().mockRejectedValue(new Error('Unable to query organizations. Please try again.')) const affiliationLoader = loadAffiliationConnectionsByUserId({ query, @@ -4319,9 +4132,7 @@ describe('given the load affiliations by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to query affiliation(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to query affiliation(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -4357,9 +4168,7 @@ describe('given the load affiliations by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load affiliation(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load affiliation(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -4374,8 +4183,8 @@ describe('given the load affiliations by user id function', () => { i18n = setupI18n({ locale: 'fr', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -4467,11 +4276,7 @@ describe('given the load affiliations by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` sur la connexion `Affiliation` ne peut être inférieur à zéro.', - ), - ) + expect(err).toEqual(new Error('`first` sur la connexion `Affiliation` ne peut être inférieur à zéro.')) } expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` set below zero for: loadAffiliationConnectionsByUserId.`, @@ -4498,11 +4303,7 @@ describe('given the load affiliations by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` sur la connexion `Affiliation` ne peut être inférieur à zéro.', - ), - ) + expect(err).toEqual(new Error('`last` sur la connexion `Affiliation` ne peut être inférieur à zéro.')) } expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`last\` set below zero for: loadAffiliationConnectionsByUserId.`, @@ -4577,9 +4378,7 @@ describe('given the load affiliations by user id function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadAffiliationConnectionsByUserId({ query, language: 'en', @@ -4598,9 +4397,7 @@ describe('given the load affiliations by user id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -4613,9 +4410,7 @@ describe('given the load affiliations by user id function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadAffiliationConnectionsByUserId({ query, language: 'en', @@ -4634,9 +4429,7 @@ describe('given the load affiliations by user id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -4652,11 +4445,7 @@ describe('given the load affiliations by user id function', () => { describe('given a database error', () => { describe('while querying domains', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue( - new Error('Unable to query organizations. Please try again.'), - ) + const query = jest.fn().mockRejectedValue(new Error('Unable to query organizations. Please try again.')) const affiliationLoader = loadAffiliationConnectionsByUserId({ query, @@ -4670,13 +4459,9 @@ describe('given the load affiliations by user id function', () => { first: 5, } try { - await affiliationLoader({userId: user._id, ...connectionArgs}) + await affiliationLoader({ userId: user._id, ...connectionArgs }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de demander l'affiliation (s). Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de demander l'affiliation (s). Veuillez réessayer.")) } expect(consoleOutput).toEqual([ @@ -4707,13 +4492,9 @@ describe('given the load affiliations by user id function', () => { first: 5, } try { - await affiliationLoader({userId: user._id, ...connectionArgs}) + await affiliationLoader({ userId: user._id, ...connectionArgs }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger l'affiliation (s). Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger l'affiliation (s). Veuillez réessayer.")) } expect(consoleOutput).toEqual([ diff --git a/api/src/affiliation/loaders/load-affiliation-connections-by-org-id.js b/api/src/affiliation/loaders/load-affiliation-connections-by-org-id.js index 1c8614e8a5..578943de5a 100644 --- a/api/src/affiliation/loaders/load-affiliation-connections-by-org-id.js +++ b/api/src/affiliation/loaders/load-affiliation-connections-by-org-id.js @@ -188,15 +188,27 @@ export const loadAffiliationConnectionsByOrgId = search = cleanseInput(search) userSearchQuery = aql` LET tokenArr = TOKENS(${search}, "text_en") - LET userIds = UNIQUE( - FOR token IN tokenArr + LET searchedDisplayNamesCount = FLATTEN( + FOR tokenItem in tokenArr + LET token = LOWER(tokenItem) FOR user IN userSearch SEARCH ANALYZER( user.displayName LIKE CONCAT("%", token, "%") - OR user.userName LIKE CONCAT("%", token, "%") , "text_en") - RETURN user._id + COLLECT currentUserId = user._id WITH COUNT INTO count + RETURN { + 'user': currentUserId, + 'count': count + } ) + LET searchedDisplayNames = searchedDisplayNamesCount[* FILTER CURRENT.count == LENGTH(tokenArr)].user + LET searchedUserNames = ( + FOR user IN users + FILTER LOWER(user.userName) LIKE CONCAT("%", LOWER(${search}), "%") + RETURN user._id + ) + LET userIds = UNIQUE(APPEND(searchedDisplayNames, searchedUserNames)) + ` userIdFilter = aql`FILTER e._to IN userIds` } diff --git a/api/src/affiliation/mutations/__tests__/invite-user-to-org.test.js b/api/src/affiliation/mutations/__tests__/invite-user-to-org.test.js index 83e8adba4b..d238041b89 100644 --- a/api/src/affiliation/mutations/__tests__/invite-user-to-org.test.js +++ b/api/src/affiliation/mutations/__tests__/invite-user-to-org.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { setupI18n } from '@lingui/core' import { graphql, GraphQLSchema } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/affiliation/mutations/__tests__/leave-organization.test.js b/api/src/affiliation/mutations/__tests__/leave-organization.test.js index 434943b4c1..45cf912f73 100644 --- a/api/src/affiliation/mutations/__tests__/leave-organization.test.js +++ b/api/src/affiliation/mutations/__tests__/leave-organization.test.js @@ -1,5 +1,6 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/affiliation/mutations/__tests__/remove-user-from-org.test.js b/api/src/affiliation/mutations/__tests__/remove-user-from-org.test.js index d22a41d869..48ff1d615c 100644 --- a/api/src/affiliation/mutations/__tests__/remove-user-from-org.test.js +++ b/api/src/affiliation/mutations/__tests__/remove-user-from-org.test.js @@ -1,5 +1,6 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/affiliation/mutations/__tests__/request-org-affiliation.test.js b/api/src/affiliation/mutations/__tests__/request-org-affiliation.test.js index a2fbaa5ab2..2920c8a119 100644 --- a/api/src/affiliation/mutations/__tests__/request-org-affiliation.test.js +++ b/api/src/affiliation/mutations/__tests__/request-org-affiliation.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { setupI18n } from '@lingui/core' import { graphql, GraphQLSchema } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/affiliation/mutations/__tests__/transfer-org-ownership.test.js b/api/src/affiliation/mutations/__tests__/transfer-org-ownership.test.js index 8a74b44ef7..ad00f21f0e 100644 --- a/api/src/affiliation/mutations/__tests__/transfer-org-ownership.test.js +++ b/api/src/affiliation/mutations/__tests__/transfer-org-ownership.test.js @@ -1,5 +1,6 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/affiliation/mutations/__tests__/update-user-role.test.js b/api/src/affiliation/mutations/__tests__/update-user-role.test.js index 71f0963916..465de80860 100644 --- a/api/src/affiliation/mutations/__tests__/update-user-role.test.js +++ b/api/src/affiliation/mutations/__tests__/update-user-role.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { setupI18n } from '@lingui/core' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/audit-logs/loaders/__tests__/load-audit-logs-by-org-id.test.js b/api/src/audit-logs/loaders/__tests__/load-audit-logs-by-org-id.test.js index 473255bed8..f7a7694b13 100644 --- a/api/src/audit-logs/loaders/__tests__/load-audit-logs-by-org-id.test.js +++ b/api/src/audit-logs/loaders/__tests__/load-audit-logs-by-org-id.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' @@ -252,11 +253,7 @@ describe('given the load log connection using org id function', () => { describe('order direction is ASC', () => { it('returns logs in order', async () => { const logLoader = loadAuditLogByKey({ query }) - const expectedLogs = await logLoader.loadMany([ - log1._key, - log2._key, - log3._key, - ]) + const expectedLogs = await logLoader.loadMany([log1._key, log2._key, log3._key]) expectedLogs[0].id = expectedLogs[0]._key expectedLogs[1].id = expectedLogs[1]._key @@ -341,9 +338,7 @@ describe('given the load log connection using org id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `You must provide a \`first\` or \`last\` value to properly paginate the \`Log\` connection.`, - ), + new Error(`You must provide a \`first\` or \`last\` value to properly paginate the \`Log\` connection.`), ) } @@ -373,9 +368,7 @@ describe('given the load log connection using org id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `Passing both \`first\` and \`last\` to paginate the \`Log\` connection is not supported.`, - ), + new Error(`Passing both \`first\` and \`last\` to paginate the \`Log\` connection is not supported.`), ) } @@ -404,11 +397,7 @@ describe('given the load log connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` on the \`Log\` connection cannot be less than zero.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` on the \`Log\` connection cannot be less than zero.`)) } expect(consoleOutput).toEqual([ @@ -435,11 +424,7 @@ describe('given the load log connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` on the \`Log\` connection cannot be less than zero.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` on the \`Log\` connection cannot be less than zero.`)) } expect(consoleOutput).toEqual([ @@ -516,9 +501,7 @@ describe('given the load log connection using org id function', () => { describe('given a database error', () => { describe('when gathering log keys that are claimed by orgs that the user has affiliations to', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database Error Occurred.')) + const query = jest.fn().mockRejectedValue(new Error('Database Error Occurred.')) const connectionLoader = loadAuditLogsByOrgId({ query, @@ -537,9 +520,7 @@ describe('given the load log connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to query log(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to query log(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -575,9 +556,7 @@ describe('given the load log connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load log(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load log(s). Please try again.')) } expect(consoleOutput).toEqual([ diff --git a/api/src/auth/__tests__/check-domain-ownership.test.js b/api/src/auth/__tests__/check-domain-ownership.test.js index 122bfd0e42..63da4128f3 100644 --- a/api/src/auth/__tests__/check-domain-ownership.test.js +++ b/api/src/auth/__tests__/check-domain-ownership.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../testUtilities' import { setupI18n } from '@lingui/core' import { checkDomainOwnership } from '../index' diff --git a/api/src/auth/__tests__/check-domain-permission.test.js b/api/src/auth/__tests__/check-domain-permission.test.js index d39b081675..e8826df6a0 100644 --- a/api/src/auth/__tests__/check-domain-permission.test.js +++ b/api/src/auth/__tests__/check-domain-permission.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../testUtilities' import { setupI18n } from '@lingui/core' import { checkDomainPermission } from '../index' diff --git a/api/src/auth/__tests__/check-org-owner.test.js b/api/src/auth/__tests__/check-org-owner.test.js index ade0b35e4c..08511f813d 100644 --- a/api/src/auth/__tests__/check-org-owner.test.js +++ b/api/src/auth/__tests__/check-org-owner.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../testUtilities' import { setupI18n } from '@lingui/core' import { checkOrgOwner } from '../check-org-owner' diff --git a/api/src/auth/__tests__/check-permission.test.js b/api/src/auth/__tests__/check-permission.test.js index 17c2a52964..67562aba43 100644 --- a/api/src/auth/__tests__/check-permission.test.js +++ b/api/src/auth/__tests__/check-permission.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../testUtilities' import { setupI18n } from '@lingui/core' import { checkPermission } from '..' diff --git a/api/src/auth/__tests__/check-super-admin.test.js b/api/src/auth/__tests__/check-super-admin.test.js index fa82565e52..4ea8f85b25 100644 --- a/api/src/auth/__tests__/check-super-admin.test.js +++ b/api/src/auth/__tests__/check-super-admin.test.js @@ -1,12 +1,13 @@ -import {ensure, dbNameFromFile} from 'arango-tools' -import {setupI18n} from '@lingui/core' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../testUtilities' +import { setupI18n } from '@lingui/core' -import {checkSuperAdmin} from '../check-super-admin' +import { checkSuperAdmin } from '../check-super-admin' import englishMessages from '../../locale/en/messages' import frenchMessages from '../../locale/fr/messages' import dbschema from '../../../database.json' -const {DB_PASS: rootPass, DB_URL: url} = process.env +const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the check super admin function', () => { let query, drop, truncate, collections, i18n, user, org @@ -22,7 +23,7 @@ describe('given the check super admin function', () => { describe('given a successful call', () => { beforeAll(async () => { - ;({query, drop, truncate, collections} = await ensure({ + ;({ query, drop, truncate, collections } = await ensure({ variables: { dbname: dbNameFromFile(__filename), username: 'root', @@ -155,8 +156,8 @@ describe('given the check super admin function', () => { i18n = setupI18n({ locale: 'en', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -167,9 +168,7 @@ describe('given the check super admin function', () => { }) describe('given a database error', () => { it('raises an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) try { const testSuperAdmin = checkSuperAdmin({ @@ -179,9 +178,7 @@ describe('given the check super admin function', () => { }) await testSuperAdmin() } catch (err) { - expect(err).toEqual( - new Error('Unable to check permission. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to check permission. Please try again.')) } expect(consoleOutput).toEqual([ @@ -206,9 +203,7 @@ describe('given the check super admin function', () => { }) await testSuperAdmin() } catch (err) { - expect(err).toEqual( - new Error('Unable to check permission. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to check permission. Please try again.')) } expect(consoleOutput).toEqual([ @@ -222,8 +217,8 @@ describe('given the check super admin function', () => { i18n = setupI18n({ locale: 'fr', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -234,9 +229,7 @@ describe('given the check super admin function', () => { }) describe('given a database error', () => { it('raises an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) try { const testSuperAdmin = checkSuperAdmin({ @@ -246,11 +239,7 @@ describe('given the check super admin function', () => { }) await testSuperAdmin() } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de vérifier l'autorisation. Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de vérifier l'autorisation. Veuillez réessayer.")) } expect(consoleOutput).toEqual([ @@ -275,11 +264,7 @@ describe('given the check super admin function', () => { }) await testSuperAdmin() } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de vérifier l'autorisation. Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de vérifier l'autorisation. Veuillez réessayer.")) } expect(consoleOutput).toEqual([ diff --git a/api/src/auth/__tests__/check-user-belongs-to-org.test.js b/api/src/auth/__tests__/check-user-belongs-to-org.test.js index 6957b05017..c9aee972fe 100644 --- a/api/src/auth/__tests__/check-user-belongs-to-org.test.js +++ b/api/src/auth/__tests__/check-user-belongs-to-org.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../testUtilities' import { setupI18n } from '@lingui/core' import { checkUserBelongsToOrg } from '../check-user-belongs-to-org' diff --git a/api/src/auth/__tests__/check-user-is-admin-for-user.test.js b/api/src/auth/__tests__/check-user-is-admin-for-user.test.js index ea90966159..b60e7f54c2 100644 --- a/api/src/auth/__tests__/check-user-is-admin-for-user.test.js +++ b/api/src/auth/__tests__/check-user-is-admin-for-user.test.js @@ -1,12 +1,13 @@ -import {ensure, dbNameFromFile} from 'arango-tools' -import {setupI18n} from '@lingui/core' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../testUtilities' +import { setupI18n } from '@lingui/core' -import {checkUserIsAdminForUser} from '../index' +import { checkUserIsAdminForUser } from '../index' import englishMessages from '../../locale/en/messages' import frenchMessages from '../../locale/fr/messages' import dbschema from '../../../database.json' -const {DB_PASS: rootPass, DB_URL: url} = process.env +const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the checkUserIsAdminForUser', () => { let query, drop, truncate, collections, i18n, user1, user2, org @@ -18,8 +19,8 @@ describe('given the checkUserIsAdminForUser', () => { i18n = setupI18n({ locale: 'fr', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -34,7 +35,7 @@ describe('given the checkUserIsAdminForUser', () => { describe('given a successful call', () => { beforeAll(async () => { - ;({query, drop, truncate, collections} = await ensure({ + ;({ query, drop, truncate, collections } = await ensure({ variables: { dbname: dbNameFromFile(__filename), username: 'root', @@ -213,8 +214,8 @@ describe('given the checkUserIsAdminForUser', () => { i18n = setupI18n({ locale: 'en', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -229,9 +230,7 @@ describe('given the checkUserIsAdminForUser', () => { const testCheck = checkUserIsAdminForUser({ i18n, userKey: user1._key, - query: jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')), + query: jest.fn().mockRejectedValue(new Error('Database error occurred.')), }) try { @@ -239,9 +238,7 @@ describe('given the checkUserIsAdminForUser', () => { userName: 'test.account2@istio.actually.exists', }) } catch (err) { - expect(err).toEqual( - Error('Permission error, not an admin for this user.'), - ) + expect(err).toEqual(Error('Permission error, not an admin for this user.')) } expect(consoleOutput).toEqual([ `Database error when checking to see if user: ${user1._key} has super admin permission for user: test.account2@istio.actually.exists, error: Error: Database error occurred.`, @@ -268,9 +265,7 @@ describe('given the checkUserIsAdminForUser', () => { userName: 'test.account2@istio.actually.exists', }) } catch (err) { - expect(err).toEqual( - Error('Permission error, not an admin for this user.'), - ) + expect(err).toEqual(Error('Permission error, not an admin for this user.')) } expect(consoleOutput).toEqual([ `Database error when checking to see if user: ${user1._key} has admin permission for user: test.account2@istio.actually.exists, error: Error: Database error occurred.`, @@ -298,9 +293,7 @@ describe('given the checkUserIsAdminForUser', () => { userName: 'test.account2@istio.actually.exists', }) } catch (err) { - expect(err).toEqual( - Error('Permission error, not an admin for this user.'), - ) + expect(err).toEqual(Error('Permission error, not an admin for this user.')) } expect(consoleOutput).toEqual([ `Cursor error when checking to see if user: ${user1._key} has super admin permission for user: test.account2@istio.actually.exists, error: Error: Cursor error occurred.`, @@ -333,9 +326,7 @@ describe('given the checkUserIsAdminForUser', () => { userName: 'test.account2@istio.actually.exists', }) } catch (err) { - expect(err).toEqual( - Error('Permission error, not an admin for this user.'), - ) + expect(err).toEqual(Error('Permission error, not an admin for this user.')) } expect(consoleOutput).toEqual([ `Cursor error when checking to see if user: ${user1._key} has admin permission for user: test.account2@istio.actually.exists, error: Error: Cursor error occurred.`, @@ -349,8 +340,8 @@ describe('given the checkUserIsAdminForUser', () => { i18n = setupI18n({ locale: 'fr', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -365,9 +356,7 @@ describe('given the checkUserIsAdminForUser', () => { const testCheck = checkUserIsAdminForUser({ i18n, userKey: user1._key, - query: jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')), + query: jest.fn().mockRejectedValue(new Error('Database error occurred.')), }) try { @@ -375,11 +364,7 @@ describe('given the checkUserIsAdminForUser', () => { userName: 'test.account2@istio.actually.exists', }) } catch (err) { - expect(err).toEqual( - Error( - "Erreur de permission, pas d'administrateur pour cet utilisateur.", - ), - ) + expect(err).toEqual(Error("Erreur de permission, pas d'administrateur pour cet utilisateur.")) } expect(consoleOutput).toEqual([ `Database error when checking to see if user: ${user1._key} has super admin permission for user: test.account2@istio.actually.exists, error: Error: Database error occurred.`, @@ -406,11 +391,7 @@ describe('given the checkUserIsAdminForUser', () => { userName: 'test.account2@istio.actually.exists', }) } catch (err) { - expect(err).toEqual( - Error( - "Erreur de permission, pas d'administrateur pour cet utilisateur.", - ), - ) + expect(err).toEqual(Error("Erreur de permission, pas d'administrateur pour cet utilisateur.")) } expect(consoleOutput).toEqual([ `Database error when checking to see if user: ${user1._key} has admin permission for user: test.account2@istio.actually.exists, error: Error: Database error occurred.`, @@ -438,11 +419,7 @@ describe('given the checkUserIsAdminForUser', () => { userName: 'test.account2@istio.actually.exists', }) } catch (err) { - expect(err).toEqual( - Error( - "Erreur de permission, pas d'administrateur pour cet utilisateur.", - ), - ) + expect(err).toEqual(Error("Erreur de permission, pas d'administrateur pour cet utilisateur.")) } expect(consoleOutput).toEqual([ `Cursor error when checking to see if user: ${user1._key} has super admin permission for user: test.account2@istio.actually.exists, error: Error: Cursor error occurred.`, @@ -475,11 +452,7 @@ describe('given the checkUserIsAdminForUser', () => { userName: 'test.account2@istio.actually.exists', }) } catch (err) { - expect(err).toEqual( - Error( - "Erreur de permission, pas d'administrateur pour cet utilisateur.", - ), - ) + expect(err).toEqual(Error("Erreur de permission, pas d'administrateur pour cet utilisateur.")) } expect(consoleOutput).toEqual([ `Cursor error when checking to see if user: ${user1._key} has admin permission for user: test.account2@istio.actually.exists, error: Error: Cursor error occurred.`, diff --git a/api/src/auth/__tests__/user-required.test.js b/api/src/auth/__tests__/user-required.test.js index 96d63d02fa..c200d29069 100644 --- a/api/src/auth/__tests__/user-required.test.js +++ b/api/src/auth/__tests__/user-required.test.js @@ -1,13 +1,14 @@ -import {ensure, dbNameFromFile} from 'arango-tools' -import {setupI18n} from '@lingui/core' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../testUtilities' +import { setupI18n } from '@lingui/core' -import {loadUserByKey, loadUserByUserName} from '../../user/loaders' -import {userRequired} from '../index' +import { loadUserByKey, loadUserByUserName } from '../../user/loaders' +import { userRequired } from '../index' import englishMessages from '../../locale/en/messages' import frenchMessages from '../../locale/fr/messages' import dbschema from '../../../database.json' -const {DB_PASS: rootPass, DB_URL: url} = process.env +const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given a loadUserByKey dataloader', () => { let query, drop, truncate, collections, i18n @@ -25,7 +26,7 @@ describe('given a loadUserByKey dataloader', () => { describe('given a successful call', () => { beforeAll(async () => { - ;({query, drop, truncate, collections} = await ensure({ + ;({ query, drop, truncate, collections } = await ensure({ variables: { dbname: dbNameFromFile(__filename), username: 'root', @@ -63,7 +64,7 @@ describe('given a loadUserByKey dataloader', () => { const testUserRequired = userRequired({ userKey: expectedUser._key, - loadUserByKey: loadUserByKey({query}), + loadUserByKey: loadUserByKey({ query }), }) const user = await testUserRequired() @@ -75,8 +76,8 @@ describe('given a loadUserByKey dataloader', () => { i18n = setupI18n({ locale: 'en', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -91,18 +92,14 @@ describe('given a loadUserByKey dataloader', () => { const testUserRequired = userRequired({ i18n, userKey: undefined, - loadUserByKey: loadUserByKey({query}), + loadUserByKey: loadUserByKey({ query }), }) await testUserRequired() } catch (err) { - expect(err).toEqual( - new Error('Authentication error. Please sign in.'), - ) + expect(err).toEqual(new Error('Authentication error. Please sign in.')) } - expect(consoleOutput).toEqual([ - `User attempted to access controlled content, but userKey was undefined.`, - ]) + expect(consoleOutput).toEqual([`User attempted to access controlled content, but userKey was undefined.`]) }) }) describe('user cannot be found in database', () => { @@ -113,13 +110,11 @@ describe('given a loadUserByKey dataloader', () => { const testUserRequired = userRequired({ i18n, userKey: '1', - loadUserByKey: loadUserByKey({query}), + loadUserByKey: loadUserByKey({ query }), }) await testUserRequired() } catch (err) { - expect(err).toEqual( - new Error('Authentication error. Please sign in.'), - ) + expect(err).toEqual(new Error('Authentication error. Please sign in.')) } expect(consoleOutput).toEqual([ @@ -133,8 +128,8 @@ describe('given a loadUserByKey dataloader', () => { i18n = setupI18n({ locale: 'fr', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -149,18 +144,14 @@ describe('given a loadUserByKey dataloader', () => { const testUserRequired = userRequired({ i18n, userKey: undefined, - loadUserByKey: loadUserByKey({query}), + loadUserByKey: loadUserByKey({ query }), }) await testUserRequired() } catch (err) { - expect(err).toEqual( - new Error("Erreur d'authentification. Veuillez vous connecter."), - ) + expect(err).toEqual(new Error("Erreur d'authentification. Veuillez vous connecter.")) } - expect(consoleOutput).toEqual([ - `User attempted to access controlled content, but userKey was undefined.`, - ]) + expect(consoleOutput).toEqual([`User attempted to access controlled content, but userKey was undefined.`]) }) }) describe('user cannot be found in database', () => { @@ -171,13 +162,11 @@ describe('given a loadUserByKey dataloader', () => { const testUserRequired = userRequired({ i18n, userKey: '1', - loadUserByKey: loadUserByKey({query}), + loadUserByKey: loadUserByKey({ query }), }) await testUserRequired() } catch (err) { - expect(err).toEqual( - new Error("Erreur d'authentification. Veuillez vous connecter."), - ) + expect(err).toEqual(new Error("Erreur d'authentification. Veuillez vous connecter.")) } expect(consoleOutput).toEqual([ @@ -193,8 +182,8 @@ describe('given a loadUserByKey dataloader', () => { i18n = setupI18n({ locale: 'en', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -221,9 +210,7 @@ describe('given a loadUserByKey dataloader', () => { }) await testUserRequired() } catch (err) { - expect(err).toEqual( - new Error('Authentication error. Please sign in.'), - ) + expect(err).toEqual(new Error('Authentication error. Please sign in.')) } expect(consoleOutput).toEqual([ @@ -237,8 +224,8 @@ describe('given a loadUserByKey dataloader', () => { i18n = setupI18n({ locale: 'fr', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -265,9 +252,7 @@ describe('given a loadUserByKey dataloader', () => { }) await testUserRequired() } catch (err) { - expect(err).toEqual( - new Error("Erreur d'authentification. Veuillez vous connecter."), - ) + expect(err).toEqual(new Error("Erreur d'authentification. Veuillez vous connecter.")) } expect(consoleOutput).toEqual([ diff --git a/api/src/collection-names.js b/api/src/collection-names.js index 9c51219fe1..7a4dea2260 100644 --- a/api/src/collection-names.js +++ b/api/src/collection-names.js @@ -2,6 +2,7 @@ export const collectionNames = [ 'users', 'organizations', 'domains', + 'guidanceTags', 'dkimGuidanceTags', 'dmarcGuidanceTags', 'spfGuidanceTags', diff --git a/api/src/dmarc-summaries/loaders/__tests__/load-dkim-failure-connections-by-sum-id.test.js b/api/src/dmarc-summaries/loaders/__tests__/load-dkim-failure-connections-by-sum-id.test.js index 84cfd6adab..661a6e0ab6 100644 --- a/api/src/dmarc-summaries/loaders/__tests__/load-dkim-failure-connections-by-sum-id.test.js +++ b/api/src/dmarc-summaries/loaders/__tests__/load-dkim-failure-connections-by-sum-id.test.js @@ -1,5 +1,6 @@ import { stringify } from 'jest-matcher-utils' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' @@ -12,15 +13,7 @@ import dbschema from '../../../../database.json' const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the loadDkimFailConnectionsBySumId loader', () => { - let query, - drop, - truncate, - collections, - i18n, - user, - dmarcSummary, - dkimFailure1, - dkimFailure2 + let query, drop, truncate, collections, i18n, user, dmarcSummary, dkimFailure1, dkimFailure2 const consoleOutput = [] const mockedError = (output) => consoleOutput.push(output) @@ -36,16 +29,16 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { describe('given a successful load', () => { beforeEach(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, - - schema: dbschema, - })) + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, + + schema: dbschema, + })) user = await collections.users.save({ userName: 'test.account@istio.actually.exists', displayName: 'Test Account', @@ -453,11 +446,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` on the `DkimFailureTable` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`first` on the `DkimFailureTable` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ @@ -483,11 +472,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` on the `DkimFailureTable` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`last` on the `DkimFailureTable` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ @@ -499,9 +484,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { describe('first or last argument is not set to a number', () => { describe('first argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDkimFailConnectionsBySumId({ query, userKey: user._key, @@ -519,11 +502,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -535,9 +514,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { }) describe('last argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDkimFailConnectionsBySumId({ query, userKey: user._key, @@ -555,11 +532,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -587,11 +560,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - 'Unable to load DKIM failure data. Please try again.', - ), - ) + expect(err).toEqual(new Error('Unable to load DKIM failure data. Please try again.')) } expect(consoleOutput).toEqual([ @@ -602,9 +571,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { }) describe('given a database error occurs', () => { it('returns an error message', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const connectionLoader = loadDkimFailConnectionsBySumId({ query: mockedQuery, @@ -622,9 +589,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load DKIM failure data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load DKIM failure data. Please try again.')) } expect(consoleOutput).toEqual([ @@ -657,9 +622,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load DKIM failure data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load DKIM failure data. Please try again.')) } expect(consoleOutput).toEqual([ @@ -826,9 +789,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`first` sur la connexion `DkimFailureTable` ne peut être inférieur à zéro.', - ), + new Error('`first` sur la connexion `DkimFailureTable` ne peut être inférieur à zéro.'), ) } @@ -856,9 +817,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`last` sur la connexion `DkimFailureTable` ne peut être inférieur à zéro.', - ), + new Error('`last` sur la connexion `DkimFailureTable` ne peut être inférieur à zéro.'), ) } @@ -871,9 +830,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { describe('first or last argument is not set to a number', () => { describe('first argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDkimFailConnectionsBySumId({ query, userKey: user._key, @@ -892,9 +849,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -907,9 +862,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { }) describe('last argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDkimFailConnectionsBySumId({ query, userKey: user._key, @@ -928,9 +881,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -959,11 +910,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger les données d'échec DKIM. Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger les données d'échec DKIM. Veuillez réessayer.")) } expect(consoleOutput).toEqual([ @@ -974,9 +921,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { }) describe('given a database error occurs', () => { it('returns an error message', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const connectionLoader = loadDkimFailConnectionsBySumId({ query: mockedQuery, @@ -994,11 +939,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger les données d'échec DKIM. Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger les données d'échec DKIM. Veuillez réessayer.")) } expect(consoleOutput).toEqual([ @@ -1031,11 +972,7 @@ describe('given the loadDkimFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger les données d'échec DKIM. Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger les données d'échec DKIM. Veuillez réessayer.")) } expect(consoleOutput).toEqual([ diff --git a/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-failure-connections-by-sum-id.test.js b/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-failure-connections-by-sum-id.test.js index a256ec36a6..5ad930eacd 100644 --- a/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-failure-connections-by-sum-id.test.js +++ b/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-failure-connections-by-sum-id.test.js @@ -1,5 +1,6 @@ import { stringify } from 'jest-matcher-utils' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' @@ -12,15 +13,7 @@ import dbschema from '../../../../database.json' const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the loadDmarcFailConnectionsBySumId loader', () => { - let query, - drop, - truncate, - collections, - i18n, - user, - dmarcSummary, - dmarcFailure1, - dmarcFailure2 + let query, drop, truncate, collections, i18n, user, dmarcSummary, dmarcFailure1, dmarcFailure2 const consoleOutput = [] const mockedError = (output) => consoleOutput.push(output) @@ -37,16 +30,16 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { describe('given a successful load', () => { beforeEach(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, - - schema: dbschema, - })) + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, + + schema: dbschema, + })) user = await collections.users.save({ userName: 'test.account@istio.actually.exists', displayName: 'Test Account', @@ -448,9 +441,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { await connectionLoader({ ...connectionArgs }) } catch (err) { expect(err).toEqual( - new Error( - '`first` on the `DmarcFailureTable` connection cannot be less than zero.', - ), + new Error('`first` on the `DmarcFailureTable` connection cannot be less than zero.'), ) } @@ -476,11 +467,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { try { await connectionLoader({ ...connectionArgs }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` on the `DmarcFailureTable` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`last` on the `DmarcFailureTable` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ @@ -492,9 +479,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { describe('first or last argument is not set to a number', () => { describe('first argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDmarcFailConnectionsBySumId({ query, userKey: user._key, @@ -512,11 +497,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -528,9 +509,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { }) describe('last argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDmarcFailConnectionsBySumId({ query, userKey: user._key, @@ -548,11 +527,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -579,11 +554,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { try { await connectionLoader({ ...connectionArgs }) } catch (err) { - expect(err).toEqual( - new Error( - 'Unable to load DMARC failure data. Please try again.', - ), - ) + expect(err).toEqual(new Error('Unable to load DMARC failure data. Please try again.')) } expect(consoleOutput).toEqual([ @@ -594,9 +565,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { }) describe('given a database error', () => { it('returns an error message', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const connectionLoader = loadDmarcFailConnectionsBySumId({ query: mockedQuery, @@ -614,9 +583,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load DMARC failure data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load DMARC failure data. Please try again.')) } expect(consoleOutput).toEqual([ @@ -649,9 +616,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load DMARC failure data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load DMARC failure data. Please try again.')) } expect(consoleOutput).toEqual([ @@ -813,9 +778,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { await connectionLoader({ ...connectionArgs }) } catch (err) { expect(err).toEqual( - new Error( - '`first` sur la connexion `DmarcFailureTable` ne peut être inférieur à zéro.', - ), + new Error('`first` sur la connexion `DmarcFailureTable` ne peut être inférieur à zéro.'), ) } @@ -842,9 +805,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { await connectionLoader({ ...connectionArgs }) } catch (err) { expect(err).toEqual( - new Error( - '`last` sur la connexion `DmarcFailureTable` ne peut être inférieur à zéro.', - ), + new Error('`last` sur la connexion `DmarcFailureTable` ne peut être inférieur à zéro.'), ) } @@ -857,9 +818,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { describe('first or last argument is not set to a number', () => { describe('first argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDmarcFailConnectionsBySumId({ query, userKey: user._key, @@ -878,9 +837,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -893,9 +850,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { }) describe('last argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDmarcFailConnectionsBySumId({ query, userKey: user._key, @@ -914,9 +869,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -944,11 +897,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { try { await connectionLoader({ ...connectionArgs }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger les données d'échec DMARC. Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger les données d'échec DMARC. Veuillez réessayer.")) } expect(consoleOutput).toEqual([ @@ -959,9 +908,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { }) describe('given a database error', () => { it('returns an error message', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const connectionLoader = loadDmarcFailConnectionsBySumId({ query: mockedQuery, @@ -979,11 +926,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger les données d'échec DMARC. Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger les données d'échec DMARC. Veuillez réessayer.")) } expect(consoleOutput).toEqual([ @@ -1016,11 +959,7 @@ describe('given the loadDmarcFailConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger les données d'échec DMARC. Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger les données d'échec DMARC. Veuillez réessayer.")) } expect(consoleOutput).toEqual([ diff --git a/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-sum-connections-by-user-id.test.js b/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-sum-connections-by-user-id.test.js index 2d3e88ba4a..a2801d6834 100644 --- a/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-sum-connections-by-user-id.test.js +++ b/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-sum-connections-by-user-id.test.js @@ -1,31 +1,19 @@ import { stringify } from 'jest-matcher-utils' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' import frenchMessages from '../../../locale/fr/messages' import { cleanseInput } from '../../../validators' -import { - loadDmarcSummaryConnectionsByUserId, - loadDmarcSummaryByKey, -} from '../index' +import { loadDmarcSummaryConnectionsByUserId, loadDmarcSummaryByKey } from '../index' import dbschema from '../../../../database.json' const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the loadDmarcSummaryConnectionsByUserId function', () => { - let query, - drop, - truncate, - collections, - org, - i18n, - user, - domain1, - domain2, - dmarcSummary1, - dmarcSummary2 + let query, drop, truncate, collections, org, i18n, user, domain1, domain2, dmarcSummary1, dmarcSummary2 const consoleOutput = [] const mockedError = (output) => consoleOutput.push(output) @@ -43,16 +31,16 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, - - schema: dbschema, - })) + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, + + schema: dbschema, + })) }) beforeEach(async () => { user = await collections.users.save({ @@ -181,9 +169,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -208,10 +194,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -231,9 +214,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -258,10 +239,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -281,9 +259,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -307,10 +283,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -330,9 +303,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -356,10 +327,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -379,10 +347,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { }) it('returns the filtered dmarc summaries', async () => { const summaryLoader = loadDmarcSummaryByKey({ query }) - const expectedSummaries = await summaryLoader.loadMany([ - dmarcSummary1._key, - dmarcSummary2._key, - ]) + const expectedSummaries = await summaryLoader.loadMany([dmarcSummary1._key, dmarcSummary2._key]) const connectionLoader = loadDmarcSummaryConnectionsByUserId({ query, @@ -390,9 +355,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -417,10 +380,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -443,9 +403,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -464,10 +422,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -477,14 +432,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -503,9 +452,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -524,10 +471,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -537,14 +481,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -565,9 +503,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -586,10 +522,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -599,14 +532,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -625,9 +552,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -646,10 +571,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -659,14 +581,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -687,9 +603,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -708,10 +622,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -721,14 +632,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -747,9 +652,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -768,10 +671,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -781,14 +681,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -809,9 +703,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -830,10 +722,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -843,14 +732,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -869,9 +752,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -890,10 +771,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -903,14 +781,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -931,9 +803,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -952,10 +822,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -965,14 +832,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -991,9 +852,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1012,10 +871,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -1025,14 +881,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -1053,9 +903,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1074,10 +922,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -1087,14 +932,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -1113,9 +952,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1134,10 +971,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -1147,14 +981,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -1175,9 +1003,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1196,10 +1022,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -1209,14 +1032,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -1235,9 +1052,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1256,10 +1071,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -1269,14 +1081,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -1297,9 +1103,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1318,10 +1122,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -1331,14 +1132,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -1357,9 +1152,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1378,10 +1171,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -1391,14 +1181,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -1419,9 +1203,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1440,10 +1222,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -1453,14 +1232,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -1479,9 +1252,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1500,10 +1271,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -1513,14 +1281,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -1541,9 +1303,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1562,10 +1322,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -1575,14 +1332,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -1601,9 +1352,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1622,10 +1371,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -1635,14 +1381,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -1665,9 +1405,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1686,10 +1424,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -1699,14 +1434,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -1725,9 +1454,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1746,10 +1473,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -1759,14 +1483,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -1787,9 +1505,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1808,10 +1524,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -1821,14 +1534,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -1847,9 +1554,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1868,10 +1573,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -1881,14 +1583,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -1909,9 +1605,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1930,10 +1624,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -1943,14 +1634,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -1969,9 +1654,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -1990,10 +1673,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -2003,14 +1683,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -2031,9 +1705,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2052,10 +1724,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -2065,14 +1734,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -2091,9 +1754,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2112,10 +1773,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -2125,14 +1783,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -2153,9 +1805,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2174,10 +1824,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -2187,14 +1834,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -2213,9 +1854,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2234,10 +1873,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -2247,14 +1883,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -2275,9 +1905,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2296,10 +1924,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -2309,14 +1934,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -2335,9 +1954,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2356,10 +1973,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -2369,14 +1983,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -2397,9 +2005,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2418,10 +2024,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -2431,14 +2034,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -2457,9 +2054,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2478,10 +2073,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -2491,14 +2083,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -2519,9 +2105,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2540,10 +2124,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -2553,14 +2134,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -2579,9 +2154,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2600,10 +2173,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -2613,14 +2183,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -2641,9 +2205,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2662,10 +2224,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -2675,14 +2234,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -2701,9 +2254,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2722,10 +2273,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -2735,14 +2283,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -2763,9 +2305,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2784,10 +2324,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), node: { ...expectedSummaries[0], }, @@ -2797,14 +2334,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), }, } @@ -2823,9 +2354,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2844,10 +2373,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + cursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), node: { ...expectedSummaries[1], }, @@ -2857,14 +2383,8 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), - endCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[1]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), + endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -2886,9 +2406,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n: {}, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -2919,10 +2437,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: false, - startCursor: toGlobalId( - 'dmarcSummary', - expectedSummaries[0]._key, - ), + startCursor: toGlobalId('dmarcSummary', expectedSummaries[0]._key), endCursor: toGlobalId('dmarcSummary', expectedSummaries[1]._key), }, } @@ -3043,9 +2558,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3077,9 +2590,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3114,9 +2625,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3149,9 +2658,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3186,9 +2693,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3202,11 +2707,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` on the `DmarcSummaries` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`first` on the `DmarcSummaries` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` set below zero for: loadDmarcSummaryConnectionsByUserId.`, @@ -3221,9 +2722,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3237,11 +2736,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` on the `DmarcSummaries` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`last` on the `DmarcSummaries` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`last\` set below zero for: loadDmarcSummaryConnectionsByUserId.`, @@ -3252,18 +2747,14 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDmarcSummaryConnectionsByUserId({ query, userKey: user._key, cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3277,11 +2768,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -3293,18 +2780,14 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDmarcSummaryConnectionsByUserId({ query, userKey: user._key, cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3318,11 +2801,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -3341,9 +2820,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3357,9 +2834,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - 'You must provide a `period` value to access the `DmarcSummaries` connection.', - ), + new Error('You must provide a `period` value to access the `DmarcSummaries` connection.'), ) } expect(consoleOutput).toEqual([ @@ -3375,9 +2850,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3391,9 +2864,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - 'You must provide a `year` value to access the `DmarcSummaries` connection.', - ), + new Error('You must provide a `year` value to access the `DmarcSummaries` connection.'), ) } expect(consoleOutput).toEqual([ @@ -3404,9 +2875,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { describe('given a database error', () => { describe('while querying for domain information', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const query = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const connectionLoader = loadDmarcSummaryConnectionsByUserId({ query, @@ -3414,9 +2883,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3429,11 +2896,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - 'Unable to load DMARC summary data. Please try again.', - ), - ) + expect(err).toEqual(new Error('Unable to load DMARC summary data. Please try again.')) } expect(consoleOutput).toEqual([ @@ -3458,9 +2921,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3473,11 +2934,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - 'Unable to load DMARC summary data. Please try again.', - ), - ) + expect(err).toEqual(new Error('Unable to load DMARC summary data. Please try again.')) } expect(consoleOutput).toEqual([ @@ -3512,9 +2969,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3546,9 +3001,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3583,9 +3036,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3618,9 +3069,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3655,9 +3104,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3672,9 +3119,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`first` sur la connexion `DmarcSummaries` ne peut être inférieur à zéro.', - ), + new Error('`first` sur la connexion `DmarcSummaries` ne peut être inférieur à zéro.'), ) } expect(consoleOutput).toEqual([ @@ -3690,9 +3135,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3707,9 +3150,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`last` sur la connexion `DmarcSummaries` ne peut être inférieur à zéro.', - ), + new Error('`last` sur la connexion `DmarcSummaries` ne peut être inférieur à zéro.'), ) } expect(consoleOutput).toEqual([ @@ -3721,18 +3162,14 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDmarcSummaryConnectionsByUserId({ query, userKey: user._key, cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3747,9 +3184,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -3762,18 +3197,14 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDmarcSummaryConnectionsByUserId({ query, userKey: user._key, cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3788,9 +3219,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -3810,9 +3239,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3826,9 +3253,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - 'Vous devez fournir une valeur `period` pour accéder à la connexion `DmarcSummaries`.', - ), + new Error('Vous devez fournir une valeur `period` pour accéder à la connexion `DmarcSummaries`.'), ) } expect(consoleOutput).toEqual([ @@ -3844,9 +3269,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3860,9 +3283,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - 'Vous devez fournir une valeur `year` pour accéder à la connexion `DmarcSummaries`.', - ), + new Error('Vous devez fournir une valeur `year` pour accéder à la connexion `DmarcSummaries`.'), ) } expect(consoleOutput).toEqual([ @@ -3873,9 +3294,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { describe('given a database error', () => { describe('while querying for domain information', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const query = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const connectionLoader = loadDmarcSummaryConnectionsByUserId({ query, @@ -3883,9 +3302,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3899,9 +3316,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - 'Impossible de charger les données de synthèse DMARC. Veuillez réessayer.', - ), + new Error('Impossible de charger les données de synthèse DMARC. Veuillez réessayer.'), ) } @@ -3927,9 +3342,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { cleanseInput, auth: { loginRequired: true }, i18n, - loadStartDateFromPeriod: jest - .fn() - .mockReturnValueOnce('thirtyDays'), + loadStartDateFromPeriod: jest.fn().mockReturnValueOnce('thirtyDays'), }) const connectionArgs = { @@ -3943,9 +3356,7 @@ describe('given the loadDmarcSummaryConnectionsByUserId function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - 'Impossible de charger les données de synthèse DMARC. Veuillez réessayer.', - ), + new Error('Impossible de charger les données de synthèse DMARC. Veuillez réessayer.'), ) } diff --git a/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-sum-edge-by-domain-id-period.test.js b/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-sum-edge-by-domain-id-period.test.js index c434fd36ef..1e10e7aaa9 100644 --- a/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-sum-edge-by-domain-id-period.test.js +++ b/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-sum-edge-by-domain-id-period.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' @@ -26,16 +27,16 @@ describe('given the loadDmarcSummaryEdgeByDomainIdAndPeriod loader', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, - - schema: dbschema, - })) + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, + + schema: dbschema, + })) }) beforeEach(async () => { user = await collections.users.save({ @@ -45,7 +46,7 @@ describe('given the loadDmarcSummaryEdgeByDomainIdAndPeriod loader', () => { tfaValidated: false, emailValidated: false, }) - + dmarcSummary = await collections.dmarcSummaries.save({ detailTables: { dkimFailure: [], @@ -111,27 +112,23 @@ describe('given the loadDmarcSummaryEdgeByDomainIdAndPeriod loader', () => { }) describe('given a database error', () => { it('throws an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred')) - + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred')) + const loader = loadDmarcSummaryEdgeByDomainIdAndPeriod({ query: mockedQuery, userKey: user._key, i18n, }) - + try { await loader({ domainId: 'domains/1', startDate: 'thirtyDays', }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load DMARC summary data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load DMARC summary data. Please try again.')) } - + expect(consoleOutput).toEqual([ `Database error occurred when user: ${user._key} attempted to load dmarc summaries for domain: domains/1, period: thirtyDays, Error: Database error occurred`, ]) @@ -145,24 +142,22 @@ describe('given the loadDmarcSummaryEdgeByDomainIdAndPeriod loader', () => { }, } const mockedQuery = jest.fn().mockReturnValueOnce(cursor) - + const loader = loadDmarcSummaryEdgeByDomainIdAndPeriod({ query: mockedQuery, userKey: user._key, i18n, }) - + try { await loader({ domainId: 'domains/1', startDate: 'thirtyDays', }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load DMARC summary data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load DMARC summary data. Please try again.')) } - + expect(consoleOutput).toEqual([ `Cursor error occurred when user: ${user._key} attempted to load dmarc summaries for domain: domains/1, period: thirtyDays, Error: Cursor error occurred.`, ]) @@ -186,29 +181,23 @@ describe('given the loadDmarcSummaryEdgeByDomainIdAndPeriod loader', () => { }) describe('given a database error', () => { it('throws an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred')) - + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred')) + const loader = loadDmarcSummaryEdgeByDomainIdAndPeriod({ query: mockedQuery, userKey: user._key, i18n, }) - + try { await loader({ domainId: 'domains/1', startDate: 'thirtyDays', }) } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger les données de synthèse DMARC. Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger les données de synthèse DMARC. Veuillez réessayer.')) } - + expect(consoleOutput).toEqual([ `Database error occurred when user: ${user._key} attempted to load dmarc summaries for domain: domains/1, period: thirtyDays, Error: Database error occurred`, ]) @@ -222,26 +211,22 @@ describe('given the loadDmarcSummaryEdgeByDomainIdAndPeriod loader', () => { }, } const mockedQuery = jest.fn().mockReturnValueOnce(cursor) - + const loader = loadDmarcSummaryEdgeByDomainIdAndPeriod({ query: mockedQuery, userKey: user._key, i18n, }) - + try { await loader({ domainId: 'domains/1', startDate: 'thirtyDays', }) } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger les données de synthèse DMARC. Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger les données de synthèse DMARC. Veuillez réessayer.')) } - + expect(consoleOutput).toEqual([ `Cursor error occurred when user: ${user._key} attempted to load dmarc summaries for domain: domains/1, period: thirtyDays, Error: Cursor error occurred.`, ]) diff --git a/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-summary-by-key.test.js b/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-summary-by-key.test.js index 026dd709c2..33626679d4 100644 --- a/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-summary-by-key.test.js +++ b/api/src/dmarc-summaries/loaders/__tests__/load-dmarc-summary-by-key.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' @@ -9,14 +10,7 @@ import dbschema from '../../../../database.json' const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the loadDmarcSummaryByKey dataloader', () => { - let query, - drop, - truncate, - collections, - i18n, - domain, - dmarcSummary1, - dmarcSummary2 + let query, drop, truncate, collections, i18n, domain, dmarcSummary1, dmarcSummary2 const consoleOutput = [] const mockedError = (output) => consoleOutput.push(output) @@ -30,16 +24,16 @@ describe('given the loadDmarcSummaryByKey dataloader', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, - schema: dbschema, - })) + schema: dbschema, + })) }) beforeEach(async () => { domain = await collections.domains.save({ @@ -108,13 +102,13 @@ describe('given the loadDmarcSummaryByKey dataloader', () => { it('returns a single dmarc summary', async () => { const expectedCursor = await query` FOR summary IN dmarcSummaries - SORT summary._key ASC + SORT summary._key ASC LIMIT 1 LET edge = ( FOR v, e IN 1..1 ANY summary._id domainsToDmarcSummaries RETURN e ) - + RETURN { _id: summary._id, _key: summary._key, @@ -131,9 +125,7 @@ describe('given the loadDmarcSummaryByKey dataloader', () => { const expectedSummary = await expectedCursor.next() expectedSummary.domainKey = domain._key - const summary = await loadDmarcSummaryByKey({ query }).load( - expectedSummary._key, - ) + const summary = await loadDmarcSummaryByKey({ query }).load(expectedSummary._key) expect(summary).toEqual(expectedSummary) }) @@ -148,7 +140,7 @@ describe('given the loadDmarcSummaryByKey dataloader', () => { FOR v, e IN 1..1 ANY summary._id domainsToDmarcSummaries RETURN e ) - + RETURN { _id: summary._id, _key: summary._key, @@ -169,9 +161,7 @@ describe('given the loadDmarcSummaryByKey dataloader', () => { expectedSummaries.push(temp) } - const summaries = await loadDmarcSummaryByKey({ query }).loadMany( - summaryKeys, - ) + const summaries = await loadDmarcSummaryByKey({ query }).loadMany(summaryKeys) expect(summaries).toEqual(expectedSummaries) }) @@ -194,18 +184,12 @@ describe('given the loadDmarcSummaryByKey dataloader', () => { }) describe('database error occurs', () => { it('throws an error', async () => { - query = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + query = jest.fn().mockRejectedValue(new Error('Database error occurred.')) try { - await loadDmarcSummaryByKey({ query, userKey: '1234', i18n }).load( - '1234', - ) + await loadDmarcSummaryByKey({ query, userKey: '1234', i18n }).load('1234') } catch (err) { - expect(err).toEqual( - new Error('Unable to find DMARC summary data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to find DMARC summary data. Please try again.')) } expect(consoleOutput).toEqual([ `Database error occurred when user: 1234 running loadDmarcSummaryByKey: Error: Database error occurred.`, @@ -222,13 +206,9 @@ describe('given the loadDmarcSummaryByKey dataloader', () => { query = jest.fn().mockReturnValue(cursor) try { - await loadDmarcSummaryByKey({ query, userKey: '1234', i18n }).load( - '1234', - ) + await loadDmarcSummaryByKey({ query, userKey: '1234', i18n }).load('1234') } catch (err) { - expect(err).toEqual( - new Error('Unable to find DMARC summary data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to find DMARC summary data. Please try again.')) } expect(consoleOutput).toEqual([ @@ -254,20 +234,12 @@ describe('given the loadDmarcSummaryByKey dataloader', () => { }) describe('database error occurs', () => { it('throws an error', async () => { - query = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + query = jest.fn().mockRejectedValue(new Error('Database error occurred.')) try { - await loadDmarcSummaryByKey({ query, userKey: '1234', i18n }).load( - '1234', - ) + await loadDmarcSummaryByKey({ query, userKey: '1234', i18n }).load('1234') } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de trouver les données de synthèse DMARC. Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de trouver les données de synthèse DMARC. Veuillez réessayer.')) } expect(consoleOutput).toEqual([ `Database error occurred when user: 1234 running loadDmarcSummaryByKey: Error: Database error occurred.`, @@ -284,15 +256,9 @@ describe('given the loadDmarcSummaryByKey dataloader', () => { query = jest.fn().mockReturnValue(cursor) try { - await loadDmarcSummaryByKey({ query, userKey: '1234', i18n }).load( - '1234', - ) + await loadDmarcSummaryByKey({ query, userKey: '1234', i18n }).load('1234') } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de trouver les données de synthèse DMARC. Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de trouver les données de synthèse DMARC. Veuillez réessayer.')) } expect(consoleOutput).toEqual([ diff --git a/api/src/dmarc-summaries/loaders/__tests__/load-full-pass-connections-by-sum-id.test.js b/api/src/dmarc-summaries/loaders/__tests__/load-full-pass-connections-by-sum-id.test.js index a445adf057..392323f21a 100644 --- a/api/src/dmarc-summaries/loaders/__tests__/load-full-pass-connections-by-sum-id.test.js +++ b/api/src/dmarc-summaries/loaders/__tests__/load-full-pass-connections-by-sum-id.test.js @@ -1,5 +1,6 @@ import { stringify } from 'jest-matcher-utils' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' @@ -12,15 +13,7 @@ import dbschema from '../../../../database.json' const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the loadFullPassConnectionsBySumId loader', () => { - let query, - drop, - truncate, - collections, - i18n, - user, - dmarcSummary, - fullPass1, - fullPass2 + let query, drop, truncate, collections, i18n, user, dmarcSummary, fullPass1, fullPass2 const consoleOutput = [] const mockedError = (output) => consoleOutput.push(output) @@ -37,16 +30,16 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, - - schema: dbschema, - })) + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, + + schema: dbschema, + })) }) beforeEach(async () => { user = await collections.users.save({ @@ -56,7 +49,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { tfaValidated: false, emailValidated: false, }) - + fullPass1 = { sourceIpAddress: '123.456.78.91', envelopeFrom: 'envelope.from', @@ -68,7 +61,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { dnsHost: 'dns.host.ca', id: 1, } - + fullPass2 = { sourceIpAddress: '123.456.78.91', envelopeFrom: 'envelope.from', @@ -80,7 +73,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { dnsHost: 'dns.host.ca', id: 2, } - + dmarcSummary = await collections.dmarcSummaries.save({ detailTables: { dkimFailure: [], @@ -116,15 +109,15 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 100, after: toGlobalId('fullPass', 1), summaryId: dmarcSummary._id, } - + const summaries = await connectionLoader({ ...connectionArgs }) - + const expectedStructure = { edges: [ { @@ -143,7 +136,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { endCursor: toGlobalId('fullPass', 2), }, } - + expect(summaries).toEqual(expectedStructure) }) }) @@ -155,15 +148,15 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 100, before: toGlobalId('fullPass', 2), summaryId: dmarcSummary._id, } - + const summaries = await connectionLoader({ ...connectionArgs }) - + const expectedStructure = { edges: [ { @@ -182,7 +175,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { endCursor: toGlobalId('fullPass', 1), }, } - + expect(summaries).toEqual(expectedStructure) }) }) @@ -194,14 +187,14 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 1, summaryId: dmarcSummary._id, } - + const summaries = await connectionLoader({ ...connectionArgs }) - + const expectedStructure = { edges: [ { @@ -220,7 +213,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { endCursor: toGlobalId('fullPass', 1), }, } - + expect(summaries).toEqual(expectedStructure) }) }) @@ -232,14 +225,14 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { last: 1, summaryId: dmarcSummary._id, } - + const summaries = await connectionLoader({ ...connectionArgs }) - + const expectedStructure = { edges: [ { @@ -258,7 +251,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { endCursor: toGlobalId('fullPass', 2), }, } - + expect(summaries).toEqual(expectedStructure) }) }) @@ -266,21 +259,21 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { describe('given there are no full passes to load', () => { it('returns no full pass connections', async () => { await truncate() - + const connectionLoader = loadFullPassConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { last: 1, summaryId: dmarcSummary._id, } - + const summaries = await connectionLoader({ ...connectionArgs }) - + const expectedStructure = { edges: [], totalCount: 0, @@ -291,7 +284,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { endCursor: '', }, } - + expect(summaries).toEqual(expectedStructure) }) }) @@ -321,7 +314,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { summaryId: '', } @@ -336,7 +329,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} did not have either \`first\` or \`last\` arguments set for: loadFullPassConnectionsBySumId.`, ]) @@ -350,7 +343,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 1, last: 1, @@ -367,7 +360,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` and \`last\` arguments set for: loadFullPassConnectionsBySumId.`, ]) @@ -382,7 +375,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 101, summaryId: '', @@ -398,7 +391,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` set to 101 for: loadFullPassConnectionsBySumId.`, ]) @@ -412,7 +405,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { last: 101, summaryId: '', @@ -428,7 +421,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`last\` set to 101 for: loadFullPassConnectionsBySumId.`, ]) @@ -444,7 +437,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: -1, summaryId: '', @@ -454,13 +447,9 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` on the `FullPassTable` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`first` on the `FullPassTable` connection cannot be less than zero.')) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` set below zero for: loadFullPassConnectionsBySumId.`, ]) @@ -474,7 +463,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { last: -1, summaryId: '', @@ -484,13 +473,9 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` on the `FullPassTable` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`last` on the `FullPassTable` connection cannot be less than zero.')) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`last\` set below zero for: loadFullPassConnectionsBySumId.`, ]) @@ -500,31 +485,25 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { describe('first or last argument is not set to a number', () => { describe('first argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadFullPassConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { first: invalidInput, summaryId: '', } - + try { await connectionLoader({ ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -536,31 +515,25 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { }) describe('last argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadFullPassConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { last: invalidInput, summaryId: '', } - + try { await connectionLoader({ ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -579,7 +552,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { last: 1, } @@ -588,11 +561,9 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load full pass data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load full pass data. Please try again.')) } - + expect(consoleOutput).toEqual([ `SummaryId was undefined when user: ${user._key} attempted to load full passes in loadFullPassConnectionsBySumId.`, ]) @@ -601,17 +572,15 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { }) describe('given a database error occurs', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) - + const query = jest.fn().mockRejectedValue(new Error('Database error occurred.')) + const connectionLoader = loadFullPassConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { first: 50, summaryId: '', @@ -621,11 +590,9 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load full pass data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load full pass data. Please try again.')) } - + expect(consoleOutput).toEqual([ `Database error occurred while user: ${user._key} was trying to gather full passes in loadFullPassConnectionsBySumId, error: Error: Database error occurred.`, ]) @@ -639,14 +606,14 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { }, } const query = jest.fn().mockReturnValueOnce(cursor) - + const connectionLoader = loadFullPassConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { first: 50, summaryId: '', @@ -656,11 +623,9 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load full pass data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load full pass data. Please try again.')) } - + expect(consoleOutput).toEqual([ `Cursor error occurred while user: ${user._key} was trying to gather full passes in loadFullPassConnectionsBySumId, error: Error: Cursor error occurred.`, ]) @@ -691,7 +656,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { summaryId: '', } @@ -706,7 +671,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} did not have either \`first\` or \`last\` arguments set for: loadFullPassConnectionsBySumId.`, ]) @@ -720,7 +685,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 1, last: 1, @@ -737,7 +702,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` and \`last\` arguments set for: loadFullPassConnectionsBySumId.`, ]) @@ -752,7 +717,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 101, summaryId: '', @@ -768,7 +733,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` set to 101 for: loadFullPassConnectionsBySumId.`, ]) @@ -782,7 +747,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { last: 101, summaryId: '', @@ -798,7 +763,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`last\` set to 101 for: loadFullPassConnectionsBySumId.`, ]) @@ -814,7 +779,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: -1, summaryId: '', @@ -825,12 +790,10 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`first` sur la connexion `FullPassTable` ne peut être inférieur à zéro.', - ), + new Error('`first` sur la connexion `FullPassTable` ne peut être inférieur à zéro.'), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` set below zero for: loadFullPassConnectionsBySumId.`, ]) @@ -844,7 +807,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { last: -1, summaryId: '', @@ -854,13 +817,9 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` sur la connexion `FullPassTable` ne peut être inférieur à zéro.', - ), - ) + expect(err).toEqual(new Error('`last` sur la connexion `FullPassTable` ne peut être inférieur à zéro.')) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`last\` set below zero for: loadFullPassConnectionsBySumId.`, ]) @@ -870,30 +829,26 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { describe('first or last argument is not set to a number', () => { describe('first argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadFullPassConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { first: invalidInput, summaryId: '', } - + try { await connectionLoader({ ...connectionArgs, }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -906,30 +861,26 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { }) describe('last argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadFullPassConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { last: invalidInput, summaryId: '', } - + try { await connectionLoader({ ...connectionArgs, }) } catch (err) { expect(err).toEqual( - new Error( - `\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -949,7 +900,7 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { last: 1, } @@ -959,12 +910,10 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { }) } catch (err) { expect(err).toEqual( - new Error( - 'Impossible de charger les données complètes de la passe. Veuillez réessayer.', - ), + new Error('Impossible de charger les données complètes de la passe. Veuillez réessayer.'), ) } - + expect(consoleOutput).toEqual([ `SummaryId was undefined when user: ${user._key} attempted to load full passes in loadFullPassConnectionsBySumId.`, ]) @@ -973,17 +922,15 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { }) describe('given a database error occurs', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) - + const query = jest.fn().mockRejectedValue(new Error('Database error occurred.')) + const connectionLoader = loadFullPassConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { first: 50, summaryId: '', @@ -994,12 +941,10 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { }) } catch (err) { expect(err).toEqual( - new Error( - 'Impossible de charger les données complètes de la passe. Veuillez réessayer.', - ), + new Error('Impossible de charger les données complètes de la passe. Veuillez réessayer.'), ) } - + expect(consoleOutput).toEqual([ `Database error occurred while user: ${user._key} was trying to gather full passes in loadFullPassConnectionsBySumId, error: Error: Database error occurred.`, ]) @@ -1013,14 +958,14 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { }, } const query = jest.fn().mockReturnValueOnce(cursor) - + const connectionLoader = loadFullPassConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { first: 50, summaryId: '', @@ -1031,12 +976,10 @@ describe('given the loadFullPassConnectionsBySumId loader', () => { }) } catch (err) { expect(err).toEqual( - new Error( - 'Impossible de charger les données complètes de la passe. Veuillez réessayer.', - ), + new Error('Impossible de charger les données complètes de la passe. Veuillez réessayer.'), ) } - + expect(consoleOutput).toEqual([ `Cursor error occurred while user: ${user._key} was trying to gather full passes in loadFullPassConnectionsBySumId, error: Error: Cursor error occurred.`, ]) diff --git a/api/src/dmarc-summaries/loaders/__tests__/load-spf-failure-connections-by-sum-id.test.js b/api/src/dmarc-summaries/loaders/__tests__/load-spf-failure-connections-by-sum-id.test.js index 0461ca7201..f82f0db3af 100644 --- a/api/src/dmarc-summaries/loaders/__tests__/load-spf-failure-connections-by-sum-id.test.js +++ b/api/src/dmarc-summaries/loaders/__tests__/load-spf-failure-connections-by-sum-id.test.js @@ -1,5 +1,6 @@ import { stringify } from 'jest-matcher-utils' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' @@ -12,15 +13,7 @@ import dbschema from '../../../../database.json' const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the loadSpfFailureConnectionsBySumId loader', () => { - let query, - drop, - truncate, - collections, - i18n, - user, - dmarcSummary, - spfFailure1, - spfFailure2 + let query, drop, truncate, collections, i18n, user, dmarcSummary, spfFailure1, spfFailure2 const consoleOutput = [] const mockedError = (output) => consoleOutput.push(output) @@ -37,16 +30,16 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, - - schema: dbschema, - })) + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, + + schema: dbschema, + })) }) beforeEach(async () => { user = await collections.users.save({ @@ -56,7 +49,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { tfaValidated: false, emailValidated: false, }) - + spfFailure1 = { sourceIpAddress: '123.456.78.91', envelopeFrom: 'envelope.from', @@ -69,7 +62,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { dnsHost: 'dns.host.ca', guidance: '', } - + spfFailure2 = { sourceIpAddress: '123.456.78.91', envelopeFrom: 'envelope.from', @@ -82,7 +75,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { dnsHost: 'dns.host.ca', guidance: '', } - + dmarcSummary = await collections.dmarcSummaries.save({ detailTables: { dkimFailure: [], @@ -118,15 +111,15 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 100, after: toGlobalId('spfFail', 1), summaryId: dmarcSummary._id, } - + const summaries = await connectionLoader({ ...connectionArgs }) - + const expectedStructure = { edges: [ { @@ -145,7 +138,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { endCursor: toGlobalId('spfFail', 2), }, } - + expect(summaries).toEqual(expectedStructure) }) }) @@ -157,15 +150,15 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 100, before: toGlobalId('spfFail', 2), summaryId: dmarcSummary._id, } - + const summaries = await connectionLoader({ ...connectionArgs }) - + const expectedStructure = { edges: [ { @@ -184,7 +177,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { endCursor: toGlobalId('spfFail', 1), }, } - + expect(summaries).toEqual(expectedStructure) }) }) @@ -196,14 +189,14 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 1, summaryId: dmarcSummary._id, } - + const summaries = await connectionLoader({ ...connectionArgs }) - + const expectedStructure = { edges: [ { @@ -222,7 +215,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { endCursor: toGlobalId('spfFail', 1), }, } - + expect(summaries).toEqual(expectedStructure) }) }) @@ -234,14 +227,14 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { last: 1, summaryId: dmarcSummary._id, } - + const summaries = await connectionLoader({ ...connectionArgs }) - + const expectedStructure = { edges: [ { @@ -260,7 +253,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { endCursor: toGlobalId('spfFail', 2), }, } - + expect(summaries).toEqual(expectedStructure) }) }) @@ -268,21 +261,21 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { describe('given there are no spf failures to load', () => { it('returns no spf failure connections', async () => { await truncate() - + const connectionLoader = loadSpfFailureConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { first: 1, summaryId: dmarcSummary._id, } - + const summaries = await connectionLoader({ ...connectionArgs }) - + const expectedStructure = { edges: [], totalCount: 0, @@ -293,7 +286,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { endCursor: '', }, } - + expect(summaries).toEqual(expectedStructure) }) }) @@ -323,7 +316,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { summaryId: '', } @@ -338,7 +331,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} did not have either \`first\` or \`last\` arguments set for: loadSpfFailureConnectionsBySumId.`, ]) @@ -352,7 +345,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 1, last: 1, @@ -369,7 +362,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` and \`last\` arguments set for: loadSpfFailureConnectionsBySumId.`, ]) @@ -384,7 +377,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 101, summaryId: '', @@ -400,7 +393,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` set to 101 for: loadSpfFailureConnectionsBySumId.`, ]) @@ -414,7 +407,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { last: 101, summaryId: '', @@ -430,7 +423,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`last\` set to 101 for: loadSpfFailureConnectionsBySumId.`, ]) @@ -446,7 +439,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: -1, summaryId: '', @@ -456,13 +449,9 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` on the `SpfFailureTable` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`first` on the `SpfFailureTable` connection cannot be less than zero.')) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` set below zero for: loadSpfFailureConnectionsBySumId.`, ]) @@ -476,7 +465,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { last: -1, summaryId: '', @@ -486,13 +475,9 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` on the `SpfFailureTable` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`last` on the `SpfFailureTable` connection cannot be less than zero.')) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`last\` set below zero for: loadSpfFailureConnectionsBySumId.`, ]) @@ -502,31 +487,25 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { describe('first or last argument is not set to a number', () => { describe('first argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadSpfFailureConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { first: invalidInput, summaryId: '', } - + try { await connectionLoader({ ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -538,31 +517,25 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { }) describe('last argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadSpfFailureConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { last: invalidInput, summaryId: '', } - + try { await connectionLoader({ ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -581,7 +554,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 10, } @@ -590,11 +563,9 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load SPF failure data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load SPF failure data. Please try again.')) } - + expect(consoleOutput).toEqual([ `SummaryId was undefined when user: ${user._key} attempted to load spf failures in loadSpfFailureConnectionsBySumId.`, ]) @@ -603,17 +574,15 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { }) describe('given a database error', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) - + const query = jest.fn().mockRejectedValue(new Error('Database error occurred.')) + const connectionLoader = loadSpfFailureConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { first: 50, summaryId: '', @@ -623,11 +592,9 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load SPF failure data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load SPF failure data. Please try again.')) } - + expect(consoleOutput).toEqual([ `Database error occurred while user: ${user._key} was trying to gather spf failures in loadSpfFailureConnectionsBySumId, error: Error: Database error occurred.`, ]) @@ -641,14 +608,14 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { }, } const query = jest.fn().mockReturnValueOnce(cursor) - + const connectionLoader = loadSpfFailureConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { first: 50, summaryId: '', @@ -658,11 +625,9 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load SPF failure data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load SPF failure data. Please try again.')) } - + expect(consoleOutput).toEqual([ `Cursor error occurred while user: ${user._key} was trying to gather spf failures in loadSpfFailureConnectionsBySumId, error: Error: Cursor error occurred.`, ]) @@ -693,7 +658,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { summaryId: '', } @@ -708,7 +673,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} did not have either \`first\` or \`last\` arguments set for: loadSpfFailureConnectionsBySumId.`, ]) @@ -722,7 +687,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 1, last: 1, @@ -739,7 +704,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` and \`last\` arguments set for: loadSpfFailureConnectionsBySumId.`, ]) @@ -754,7 +719,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 101, summaryId: '', @@ -770,7 +735,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` set to 101 for: loadSpfFailureConnectionsBySumId.`, ]) @@ -784,7 +749,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { last: 101, summaryId: '', @@ -800,7 +765,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`last\` set to 101 for: loadSpfFailureConnectionsBySumId.`, ]) @@ -816,7 +781,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: -1, summaryId: '', @@ -827,12 +792,10 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`first` sur la connexion `SpfFailureTable` ne peut être inférieur à zéro.', - ), + new Error('`first` sur la connexion `SpfFailureTable` ne peut être inférieur à zéro.'), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`first\` set below zero for: loadSpfFailureConnectionsBySumId.`, ]) @@ -846,7 +809,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { last: -1, summaryId: '', @@ -857,12 +820,10 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`last` sur la connexion `SpfFailureTable` ne peut être inférieur à zéro.', - ), + new Error('`last` sur la connexion `SpfFailureTable` ne peut être inférieur à zéro.'), ) } - + expect(consoleOutput).toEqual([ `User: ${user._key} attempted to have \`last\` set below zero for: loadSpfFailureConnectionsBySumId.`, ]) @@ -872,30 +833,26 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { describe('first or last argument is not set to a number', () => { describe('first argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadSpfFailureConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { first: invalidInput, summaryId: '', } - + try { await connectionLoader({ ...connectionArgs, }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -908,30 +865,26 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { }) describe('last argument is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadSpfFailureConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { last: invalidInput, summaryId: '', } - + try { await connectionLoader({ ...connectionArgs, }) } catch (err) { expect(err).toEqual( - new Error( - `\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -951,7 +904,7 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { cleanseInput, i18n, }) - + const connectionArgs = { first: 10, } @@ -960,13 +913,9 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger les données d'échec SPF. Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger les données d'échec SPF. Veuillez réessayer.")) } - + expect(consoleOutput).toEqual([ `SummaryId was undefined when user: ${user._key} attempted to load spf failures in loadSpfFailureConnectionsBySumId.`, ]) @@ -975,17 +924,15 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { }) describe('given a database error', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) - + const query = jest.fn().mockRejectedValue(new Error('Database error occurred.')) + const connectionLoader = loadSpfFailureConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { first: 50, summaryId: '', @@ -995,13 +942,9 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger les données d'échec SPF. Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger les données d'échec SPF. Veuillez réessayer.")) } - + expect(consoleOutput).toEqual([ `Database error occurred while user: ${user._key} was trying to gather spf failures in loadSpfFailureConnectionsBySumId, error: Error: Database error occurred.`, ]) @@ -1015,14 +958,14 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { }, } const query = jest.fn().mockReturnValueOnce(cursor) - + const connectionLoader = loadSpfFailureConnectionsBySumId({ query, userKey: user._key, cleanseInput, i18n, }) - + const connectionArgs = { first: 50, summaryId: '', @@ -1032,13 +975,9 @@ describe('given the loadSpfFailureConnectionsBySumId loader', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger les données d'échec SPF. Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger les données d'échec SPF. Veuillez réessayer.")) } - + expect(consoleOutput).toEqual([ `Cursor error occurred while user: ${user._key} was trying to gather spf failures in loadSpfFailureConnectionsBySumId, error: Error: Cursor error occurred.`, ]) diff --git a/api/src/dmarc-summaries/loaders/__tests__/load-yearly-dmarc-sum-edges.test.js b/api/src/dmarc-summaries/loaders/__tests__/load-yearly-dmarc-sum-edges.test.js index 31c0c7d6a2..d9de9ffcdf 100644 --- a/api/src/dmarc-summaries/loaders/__tests__/load-yearly-dmarc-sum-edges.test.js +++ b/api/src/dmarc-summaries/loaders/__tests__/load-yearly-dmarc-sum-edges.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' @@ -9,15 +10,7 @@ import dbschema from '../../../../database.json' const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the loadDmarcYearlySumEdge loader', () => { - let query, - drop, - truncate, - collections, - i18n, - user, - dmarcSummary1, - dmarcSummary2, - dmarcSummary3 + let query, drop, truncate, collections, i18n, user, dmarcSummary1, dmarcSummary2, dmarcSummary3 const consoleOutput = [] const mockedError = (output) => consoleOutput.push(output) @@ -35,16 +28,16 @@ describe('given the loadDmarcYearlySumEdge loader', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, - schema: dbschema, - })) + schema: dbschema, + })) }) beforeEach(async () => { user = await collections.users.save({ @@ -154,9 +147,7 @@ describe('given the loadDmarcYearlySumEdge loader', () => { }) describe('given a database error', () => { it('throws an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred')) const loader = loadDmarcYearlySumEdge({ query: mockedQuery, @@ -170,9 +161,7 @@ describe('given the loadDmarcYearlySumEdge loader', () => { startDate: 'thirtyDays', }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load DMARC summary data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load DMARC summary data. Please try again.')) } expect(consoleOutput).toEqual([ @@ -201,9 +190,7 @@ describe('given the loadDmarcYearlySumEdge loader', () => { startDate: 'thirtyDays', }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load DMARC summary data. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load DMARC summary data. Please try again.')) } expect(consoleOutput).toEqual([ @@ -229,9 +216,7 @@ describe('given the loadDmarcYearlySumEdge loader', () => { }) describe('given a database error', () => { it('throws an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred')) const loader = loadDmarcYearlySumEdge({ query: mockedQuery, @@ -245,11 +230,7 @@ describe('given the loadDmarcYearlySumEdge loader', () => { startDate: 'thirtyDays', }) } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger les données de synthèse DMARC. Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger les données de synthèse DMARC. Veuillez réessayer.')) } expect(consoleOutput).toEqual([ @@ -278,11 +259,7 @@ describe('given the loadDmarcYearlySumEdge loader', () => { startDate: 'thirtyDays', }) } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger les données de synthèse DMARC. Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger les données de synthèse DMARC. Veuillez réessayer.')) } expect(consoleOutput).toEqual([ diff --git a/api/src/dmarc-summaries/objects/__tests__/dkim-failure-table.test.js b/api/src/dmarc-summaries/objects/__tests__/dkim-failure-table.test.js index 34448ba322..e69d17b6d7 100644 --- a/api/src/dmarc-summaries/objects/__tests__/dkim-failure-table.test.js +++ b/api/src/dmarc-summaries/objects/__tests__/dkim-failure-table.test.js @@ -142,7 +142,7 @@ describe('given the dkimFailureTable gql object', () => { const demoType = dkimFailureTableType.getFields() const expectedResults = { - _id: 'aggregateGuidanceTags/agg1', + _id: 'guidanceTags/agg1', _key: 'agg1', _rev: 'rev', _type: 'guidanceTag', @@ -165,9 +165,7 @@ describe('given the dkimFailureTable gql object', () => { {}, { loaders: { - loadAggregateGuidanceTagByTagId: { - load: jest.fn().mockReturnValue(expectedResults), - }, + loadGuidanceTagByTagId: jest.fn().mockReturnValue([expectedResults]), }, }, ), @@ -186,9 +184,7 @@ describe('given the dkimFailureTable gql object', () => { {}, { loaders: { - loadAggregateGuidanceTagByTagId: { - load: jest.fn().mockReturnValue(expectedResults), - }, + loadGuidanceTagByTagId: jest.fn().mockReturnValue(expectedResults), }, }, ), diff --git a/api/src/dmarc-summaries/objects/__tests__/spf-failure-table.test.js b/api/src/dmarc-summaries/objects/__tests__/spf-failure-table.test.js index 7a26fe8678..51f78bccce 100644 --- a/api/src/dmarc-summaries/objects/__tests__/spf-failure-table.test.js +++ b/api/src/dmarc-summaries/objects/__tests__/spf-failure-table.test.js @@ -108,7 +108,7 @@ describe('given spfFailureTable gql object', () => { const demoType = spfFailureTableType.getFields() const expectedResult = { - _id: 'aggregateGuidanceTags/agg1', + _id: 'guidanceTags/agg1', _key: 'agg1', _rev: 'rev', _type: 'guidanceTag', @@ -131,9 +131,7 @@ describe('given spfFailureTable gql object', () => { {}, { loaders: { - loadAggregateGuidanceTagByTagId: { - load: jest.fn().mockReturnValue(expectedResult), - }, + loadGuidanceTagByTagId: jest.fn().mockReturnValue([expectedResult]), }, }, ), @@ -152,9 +150,7 @@ describe('given spfFailureTable gql object', () => { {}, { loaders: { - loadAggregateGuidanceTagByTagId: { - load: jest.fn().mockReturnValue(expectedResult), - }, + loadGuidanceTagByTagId: jest.fn().mockReturnValue(expectedResult), }, }, ), diff --git a/api/src/dmarc-summaries/objects/dkim-failure-table.js b/api/src/dmarc-summaries/objects/dkim-failure-table.js index 950f312431..0cf8c738a1 100644 --- a/api/src/dmarc-summaries/objects/dkim-failure-table.js +++ b/api/src/dmarc-summaries/objects/dkim-failure-table.js @@ -1,17 +1,11 @@ -import { - GraphQLInt, - GraphQLObjectType, - GraphQLString, - GraphQLBoolean, -} from 'graphql' +import { GraphQLInt, GraphQLObjectType, GraphQLString, GraphQLBoolean } from 'graphql' import { globalIdField } from 'graphql-relay' import { guidanceTagType } from '../../guidance-tag/objects' export const dkimFailureTableType = new GraphQLObjectType({ name: 'DkimFailureTable', - description: - 'This table contains the data fields for senders who are in the DKIM fail category.', + description: 'This table contains the data fields for senders who are in the DKIM fail category.', fields: () => ({ id: globalIdField('dkimFail'), dkimAligned: { @@ -55,13 +49,10 @@ export const dkimFailureTableType = new GraphQLObjectType({ guidanceTag: { type: guidanceTagType, description: 'Guidance for any issues that were found from the report.', - resolve: async ( - { guidance }, - _args, - { loaders: { loadAggregateGuidanceTagByTagId } }, - ) => { + resolve: async ({ guidance }, _args, { loaders: { loadGuidanceTagByTagId } }) => { if (guidance) { - return await loadAggregateGuidanceTagByTagId.load(guidance) + const guidanceTags = await loadGuidanceTagByTagId({ tags: [guidance] }) + return guidanceTags[0] } return {} }, diff --git a/api/src/dmarc-summaries/objects/spf-failure-table.js b/api/src/dmarc-summaries/objects/spf-failure-table.js index 19e1e34cd3..bb5695fdb4 100644 --- a/api/src/dmarc-summaries/objects/spf-failure-table.js +++ b/api/src/dmarc-summaries/objects/spf-failure-table.js @@ -1,17 +1,11 @@ -import { - GraphQLInt, - GraphQLObjectType, - GraphQLString, - GraphQLBoolean, -} from 'graphql' +import { GraphQLInt, GraphQLObjectType, GraphQLString, GraphQLBoolean } from 'graphql' import { globalIdField } from 'graphql-relay' import { guidanceTagType } from '../../guidance-tag/objects' export const spfFailureTableType = new GraphQLObjectType({ name: 'SpfFailureTable', - description: - 'This table contains the data fields for senders who are in the SPF fail category.', + description: 'This table contains the data fields for senders who are in the SPF fail category.', fields: () => ({ id: globalIdField('spfFail'), dnsHost: { @@ -34,13 +28,10 @@ export const spfFailureTableType = new GraphQLObjectType({ guidanceTag: { type: guidanceTagType, description: 'Guidance for any issues that were found from the report.', - resolve: async ( - { guidance }, - _args, - { loaders: { loadAggregateGuidanceTagByTagId } }, - ) => { + resolve: async ({ guidance }, _args, { loaders: { loadGuidanceTagByTagId } }) => { if (guidance) { - return await loadAggregateGuidanceTagByTagId.load(guidance) + const guidanceTags = await loadGuidanceTagByTagId({ tags: [guidance] }) + return guidanceTags[0] } return {} }, diff --git a/api/src/dmarc-summaries/queries/__tests__/find-my-dmarc-summaries.test.js b/api/src/dmarc-summaries/queries/__tests__/find-my-dmarc-summaries.test.js index 232ad38df3..a24d6ffe7c 100644 --- a/api/src/dmarc-summaries/queries/__tests__/find-my-dmarc-summaries.test.js +++ b/api/src/dmarc-summaries/queries/__tests__/find-my-dmarc-summaries.test.js @@ -1,5 +1,6 @@ import moment from 'moment' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/dns-scan/objects/dkim.js b/api/src/dns-scan/objects/dkim.js index 682b6079ac..6eae47c02b 100644 --- a/api/src/dns-scan/objects/dkim.js +++ b/api/src/dns-scan/objects/dkim.js @@ -13,22 +13,22 @@ export const dkimType = new GraphQLObjectType({ positiveTags: { type: new GraphQLList(guidanceTagType), description: `List of positive tags for the scanned domain from this scan.`, - resolve: async ({ positiveTags }, _, { loaders: { loadDkimGuidanceTagByTagId } }) => { - return await loadDkimGuidanceTagByTagId({ tags: positiveTags }) + resolve: async ({ positiveTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: positiveTags }) }, }, neutralTags: { type: new GraphQLList(guidanceTagType), description: `List of neutral tags for the scanned domain from this scan.`, - resolve: async ({ neutralTags }, _, { loaders: { loadDkimGuidanceTagByTagId } }) => { - return await loadDkimGuidanceTagByTagId({ tags: neutralTags }) + resolve: async ({ neutralTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: neutralTags }) }, }, negativeTags: { type: new GraphQLList(guidanceTagType), description: `List of negative tags for the scanned domain from this scan.`, - resolve: async ({ negativeTags }, _, { loaders: { loadDkimGuidanceTagByTagId } }) => { - return await loadDkimGuidanceTagByTagId({ tags: negativeTags }) + resolve: async ({ negativeTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: negativeTags }) }, }, selectors: { diff --git a/api/src/dns-scan/objects/dmarc.js b/api/src/dns-scan/objects/dmarc.js index f907ef51f9..323de4ef31 100644 --- a/api/src/dns-scan/objects/dmarc.js +++ b/api/src/dns-scan/objects/dmarc.js @@ -39,22 +39,22 @@ subdomains where mail is failing the DMARC authentication and alignment checks.` positiveTags: { type: new GraphQLList(guidanceTagType), description: `List of positive tags for the scanned domain from this scan.`, - resolve: async ({ positiveTags }, _, { loaders: { loadDmarcGuidanceTagByTagId } }) => { - return await loadDmarcGuidanceTagByTagId({ tags: positiveTags }) + resolve: async ({ positiveTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: positiveTags }) }, }, neutralTags: { type: new GraphQLList(guidanceTagType), description: `List of neutral tags for the scanned domain from this scan.`, - resolve: async ({ neutralTags }, _, { loaders: { loadDmarcGuidanceTagByTagId } }) => { - return await loadDmarcGuidanceTagByTagId({ tags: neutralTags }) + resolve: async ({ neutralTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: neutralTags }) }, }, negativeTags: { type: new GraphQLList(guidanceTagType), description: `List of negative tags for the scanned domain from this scan.`, - resolve: async ({ negativeTags }, _, { loaders: { loadDmarcGuidanceTagByTagId } }) => { - return await loadDmarcGuidanceTagByTagId({ tags: negativeTags }) + resolve: async ({ negativeTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: negativeTags }) }, }, }), diff --git a/api/src/dns-scan/objects/spf.js b/api/src/dns-scan/objects/spf.js index 27f697aeb2..5e2fdd791e 100644 --- a/api/src/dns-scan/objects/spf.js +++ b/api/src/dns-scan/objects/spf.js @@ -27,22 +27,22 @@ export const spfType = new GraphQLObjectType({ positiveTags: { type: new GraphQLList(guidanceTagType), description: `List of positive tags for the scanned domain from this scan.`, - resolve: async ({ positiveTags }, _, { loaders: { loadSpfGuidanceTagByTagId } }) => { - return await loadSpfGuidanceTagByTagId({ tags: positiveTags }) + resolve: async ({ positiveTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: positiveTags }) }, }, neutralTags: { type: new GraphQLList(guidanceTagType), description: `List of neutral tags for the scanned domain from this scan.`, - resolve: async ({ neutralTags }, _, { loaders: { loadSpfGuidanceTagByTagId } }) => { - return await loadSpfGuidanceTagByTagId({ tags: neutralTags }) + resolve: async ({ neutralTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: neutralTags }) }, }, negativeTags: { type: new GraphQLList(guidanceTagType), description: `List of negative tags for the scanned domain from this scan.`, - resolve: async ({ negativeTags }, _, { loaders: { loadSpfGuidanceTagByTagId } }) => { - return await loadSpfGuidanceTagByTagId({ tags: negativeTags }) + resolve: async ({ negativeTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: negativeTags }) }, }, }), diff --git a/api/src/domain/inputs/domain-filter.js b/api/src/domain/inputs/domain-filter.js index 2280a63b47..be9bc516b9 100644 --- a/api/src/domain/inputs/domain-filter.js +++ b/api/src/domain/inputs/domain-filter.js @@ -1,8 +1,8 @@ import { GraphQLInputObjectType, GraphQLEnumType } from 'graphql' -import { ComparisonEnums, DomainOrderField, DomainTagLabel, StatusEnum } from '../../enums' +import { AssetStateEnums, ComparisonEnums, DomainOrderField, DomainTagLabel, StatusEnum } from '../../enums' const filterValueEnumsVals = {} -const filterValueEnums = [...StatusEnum.getValues(), ...DomainTagLabel.getValues()] +const filterValueEnums = [...StatusEnum.getValues(), ...DomainTagLabel.getValues(), ...AssetStateEnums.getValues()] filterValueEnums.forEach( ({ name, value, description }) => (filterValueEnumsVals[name] = { diff --git a/api/src/domain/loaders/__tests__/load-domain-by-domain.test.js b/api/src/domain/loaders/__tests__/load-domain-by-domain.test.js index 30d039dfa1..2e43e661e8 100644 --- a/api/src/domain/loaders/__tests__/load-domain-by-domain.test.js +++ b/api/src/domain/loaders/__tests__/load-domain-by-domain.test.js @@ -1,12 +1,13 @@ -import {ensure, dbNameFromFile} from 'arango-tools' -import {setupI18n} from '@lingui/core' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' +import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' import frenchMessages from '../../../locale/fr/messages' -import {loadDomainByDomain} from '../index' +import { loadDomainByDomain } from '../index' import dbschema from '../../../../database.json' -const {DB_PASS: rootPass, DB_URL: url} = process.env +const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given a loadDomainByDomain dataloader', () => { let query, drop, truncate, collections, i18n @@ -20,7 +21,7 @@ describe('given a loadDomainByDomain dataloader', () => { }) describe('given a successful load', () => { beforeAll(async () => { - ;({query, drop, truncate, collections} = await ensure({ + ;({ query, drop, truncate, collections } = await ensure({ variables: { dbname: dbNameFromFile(__filename), username: 'root', @@ -56,7 +57,7 @@ describe('given a loadDomainByDomain dataloader', () => { ` const expectedDomain = await expectedCursor.next() - const loader = loadDomainByDomain({query}) + const loader = loadDomainByDomain({ query }) const domain = await loader.load(expectedDomain.domain) expect(domain).toEqual(expectedDomain) @@ -77,7 +78,7 @@ describe('given a loadDomainByDomain dataloader', () => { expectedDomains.push(tempDomain) } - const loader = loadDomainByDomain({query}) + const loader = loadDomainByDomain({ query }) const domains = await loader.loadMany(domainDomains) expect(domains).toEqual(expectedDomains) }) @@ -100,9 +101,7 @@ describe('given a loadDomainByDomain dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadDomainByDomain({ query: mockedQuery, userKey: '1234', @@ -112,9 +111,7 @@ describe('given a loadDomainByDomain dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error('Unable to load domain. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load domain. Please try again.')) } expect(consoleOutput).toEqual([ @@ -139,9 +136,7 @@ describe('given a loadDomainByDomain dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error('Unable to load domain. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load domain. Please try again.')) } expect(consoleOutput).toEqual([ @@ -167,9 +162,7 @@ describe('given a loadDomainByDomain dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadDomainByDomain({ query: mockedQuery, userKey: '1234', @@ -179,9 +172,7 @@ describe('given a loadDomainByDomain dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error('Impossible de charger le domaine. Veuillez réessayer.'), - ) + expect(err).toEqual(new Error('Impossible de charger le domaine. Veuillez réessayer.')) } expect(consoleOutput).toEqual([ @@ -206,9 +197,7 @@ describe('given a loadDomainByDomain dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error('Impossible de charger le domaine. Veuillez réessayer.'), - ) + expect(err).toEqual(new Error('Impossible de charger le domaine. Veuillez réessayer.')) } expect(consoleOutput).toEqual([ diff --git a/api/src/domain/loaders/__tests__/load-domain-by-key.test.js b/api/src/domain/loaders/__tests__/load-domain-by-key.test.js index 3489843691..761eca50ea 100644 --- a/api/src/domain/loaders/__tests__/load-domain-by-key.test.js +++ b/api/src/domain/loaders/__tests__/load-domain-by-key.test.js @@ -1,12 +1,13 @@ -import {ensure, dbNameFromFile} from 'arango-tools' -import {setupI18n} from '@lingui/core' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' +import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' import frenchMessages from '../../../locale/fr/messages' -import {loadDomainByKey} from '../index' +import { loadDomainByKey } from '../index' import dbschema from '../../../../database.json' -const {DB_PASS: rootPass, DB_URL: url} = process.env +const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given a loadDomainByKey dataloader', () => { let query, drop, truncate, collections, i18n @@ -22,7 +23,7 @@ describe('given a loadDomainByKey dataloader', () => { describe('given a successful load', () => { beforeAll(async () => { - ;({query, drop, truncate, collections} = await ensure({ + ;({ query, drop, truncate, collections } = await ensure({ variables: { dbname: dbNameFromFile(__filename), username: 'root', @@ -60,7 +61,7 @@ describe('given a loadDomainByKey dataloader', () => { ` const expectedDomain = await expectedCursor.next() - const loader = loadDomainByKey({query}) + const loader = loadDomainByKey({ query }) const domain = await loader.load(expectedDomain._key) expect(domain).toEqual(expectedDomain) @@ -81,7 +82,7 @@ describe('given a loadDomainByKey dataloader', () => { expectedDomains.push(tempDomain) } - const loader = loadDomainByKey({query}) + const loader = loadDomainByKey({ query }) const domains = await loader.loadMany(domainIds) expect(domains).toEqual(expectedDomains) }) @@ -92,8 +93,8 @@ describe('given a loadDomainByKey dataloader', () => { i18n = setupI18n({ locale: 'en', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -104,9 +105,7 @@ describe('given a loadDomainByKey dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadDomainByKey({ query: mockedQuery, userKey: '1234', @@ -116,9 +115,7 @@ describe('given a loadDomainByKey dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error('Unable to load domain. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load domain. Please try again.')) } expect(consoleOutput).toEqual([ @@ -143,9 +140,7 @@ describe('given a loadDomainByKey dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error('Unable to load domain. Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load domain. Please try again.')) } expect(consoleOutput).toEqual([ @@ -159,8 +154,8 @@ describe('given a loadDomainByKey dataloader', () => { i18n = setupI18n({ locale: 'fr', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -171,9 +166,7 @@ describe('given a loadDomainByKey dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadDomainByKey({ query: mockedQuery, userKey: '1234', @@ -183,9 +176,7 @@ describe('given a loadDomainByKey dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error('Impossible de charger le domaine. Veuillez réessayer.'), - ) + expect(err).toEqual(new Error('Impossible de charger le domaine. Veuillez réessayer.')) } expect(consoleOutput).toEqual([ @@ -210,9 +201,7 @@ describe('given a loadDomainByKey dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error('Impossible de charger le domaine. Veuillez réessayer.'), - ) + expect(err).toEqual(new Error('Impossible de charger le domaine. Veuillez réessayer.')) } expect(consoleOutput).toEqual([ diff --git a/api/src/domain/loaders/__tests__/load-domain-conn-org-id.test.js b/api/src/domain/loaders/__tests__/load-domain-conn-org-id.test.js index 4d7676890b..531e91c691 100644 --- a/api/src/domain/loaders/__tests__/load-domain-conn-org-id.test.js +++ b/api/src/domain/loaders/__tests__/load-domain-conn-org-id.test.js @@ -1,27 +1,19 @@ -import {stringify} from 'jest-matcher-utils' -import {ensure, dbNameFromFile} from 'arango-tools' -import {setupI18n} from '@lingui/core' +import { stringify } from 'jest-matcher-utils' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' +import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' import frenchMessages from '../../../locale/fr/messages' -import {cleanseInput} from '../../../validators' -import {loadDomainConnectionsByOrgId, loadDomainByKey} from '../index' -import {toGlobalId} from 'graphql-relay' +import { cleanseInput } from '../../../validators' +import { loadDomainConnectionsByOrgId, loadDomainByKey } from '../index' +import { toGlobalId } from 'graphql-relay' import dbschema from '../../../../database.json' -const {DB_PASS: rootPass, DB_URL: url} = process.env +const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the load domain connection using org id function', () => { - let query, - drop, - truncate, - collections, - user, - org, - domain, - domainTwo, - i18n, - language + let query, drop, truncate, collections, user, org, domain, domainTwo, i18n, language const consoleOutput = [] const mockedError = (output) => consoleOutput.push(output) @@ -37,7 +29,7 @@ describe('given the load domain connection using org id function', () => { describe('given a successful load', () => { beforeAll(async () => { - ;({query, drop, truncate, collections} = await ensure({ + ;({ query, drop, truncate, collections } = await ensure({ variables: { dbname: dbNameFromFile(__filename), username: 'root', @@ -104,7 +96,7 @@ describe('given the load domain connection using org id function', () => { _from: org._id, _to: domain._id, tags: [], - hidden: false, + assetState: 'approved', }) domainTwo = await collections.domains.save({ domain: 'test.domain.canada.ca', @@ -123,7 +115,7 @@ describe('given the load domain connection using org id function', () => { _from: org._id, _to: domainTwo._id, tags: [], - hidden: false, + assetState: 'approved', }) }) afterEach(async () => { @@ -139,14 +131,11 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -167,7 +156,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[1], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -190,14 +179,11 @@ describe('given the load domain connection using org id function', () => { language, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -218,7 +204,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[0], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -241,14 +227,11 @@ describe('given the load domain connection using org id function', () => { language, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -268,7 +251,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[0], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -291,14 +274,11 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -318,7 +298,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[1], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -350,10 +330,10 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) - const domainLoader = loadDomainByKey({query}) + const domainLoader = loadDomainByKey({ query }) const expectedDomain = await domainLoader.load(domain._key) const connectionArgs = { @@ -362,7 +342,7 @@ describe('given the load domain connection using org id function', () => { search: 'test.domain.gc.ca', } - const domains = await connectionLoader({...connectionArgs}) + const domains = await connectionLoader({ ...connectionArgs }) const expectedStructure = { edges: [ @@ -371,7 +351,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomain, claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -395,7 +375,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const connectionArgs = { @@ -430,7 +410,7 @@ describe('given the load domain connection using org id function', () => { _from: org._id, _to: domainThree._id, tags: [], - hidden: false, + assetState: 'approved', }) await collections.ownership.save({ _from: org._id, @@ -444,13 +424,11 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequiredBool: true}, + auth: { loginRequiredBool: true }, }) - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domainThree._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domainThree._key]) expectedDomains[0].id = expectedDomains[0]._key @@ -470,7 +448,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[0], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -493,15 +471,11 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - domainThree._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key, domainThree._key]) const connectionArgs = { first: 5, @@ -519,7 +493,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[0], claimTags: [], - hidden: false, + assetState: 'approved', }, }, { @@ -527,7 +501,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[1], claimTags: [], - hidden: false, + assetState: 'approved', }, }, { @@ -535,7 +509,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[2], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -557,11 +531,8 @@ describe('given the load domain connection using org id function', () => { describe('ordering on DOMAIN', () => { describe('order direction is ASC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -579,7 +550,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -593,7 +564,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[0], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -611,11 +582,8 @@ describe('given the load domain connection using org id function', () => { }) describe('order direction is DESC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -633,7 +601,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -648,7 +616,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[1], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -668,11 +636,8 @@ describe('given the load domain connection using org id function', () => { describe('ordering on DKIM_STATUS', () => { describe('order direction is ASC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -690,7 +655,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -705,7 +670,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[0], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -723,11 +688,8 @@ describe('given the load domain connection using org id function', () => { }) describe('order direction is DESC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -745,7 +707,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -760,7 +722,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[1], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -780,11 +742,8 @@ describe('given the load domain connection using org id function', () => { describe('ordering on DMARC_STATUS', () => { describe('order direction is ASC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -802,7 +761,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -817,7 +776,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[0], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -835,11 +794,8 @@ describe('given the load domain connection using org id function', () => { }) describe('order direction is DESC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -857,7 +813,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -872,7 +828,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[1], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -892,11 +848,8 @@ describe('given the load domain connection using org id function', () => { describe('ordering on HTTPS_STATUS', () => { describe('order direction is ASC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -914,7 +867,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -929,7 +882,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[0], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -947,11 +900,8 @@ describe('given the load domain connection using org id function', () => { }) describe('order direction is DESC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -969,7 +919,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -984,7 +934,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[1], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -1004,11 +954,8 @@ describe('given the load domain connection using org id function', () => { describe('ordering on SPF_STATUS', () => { describe('order direction is ASC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -1026,7 +973,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -1041,7 +988,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[0], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -1059,11 +1006,8 @@ describe('given the load domain connection using org id function', () => { }) describe('order direction is DESC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -1081,7 +1025,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -1096,7 +1040,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[1], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -1118,11 +1062,8 @@ describe('given the load domain connection using org id function', () => { describe('ordering on DOMAIN', () => { describe('order direction is ASC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -1140,7 +1081,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -1155,7 +1096,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[1], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -1173,11 +1114,8 @@ describe('given the load domain connection using org id function', () => { }) describe('order direction is DESC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -1195,7 +1133,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -1210,7 +1148,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[0], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -1230,11 +1168,8 @@ describe('given the load domain connection using org id function', () => { describe('ordering on DKIM_STATUS', () => { describe('order direction is ASC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -1252,7 +1187,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -1267,7 +1202,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[1], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -1285,11 +1220,8 @@ describe('given the load domain connection using org id function', () => { }) describe('order direction is DESC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -1307,7 +1239,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -1322,7 +1254,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[0], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -1342,11 +1274,8 @@ describe('given the load domain connection using org id function', () => { describe('ordering on DMARC_STATUS', () => { describe('order direction is ASC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -1364,7 +1293,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -1379,7 +1308,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[1], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -1397,11 +1326,8 @@ describe('given the load domain connection using org id function', () => { }) describe('order direction is DESC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -1419,7 +1345,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -1434,7 +1360,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[0], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -1454,11 +1380,8 @@ describe('given the load domain connection using org id function', () => { describe('ordering on HTTPS_STATUS', () => { describe('order direction is ASC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -1476,7 +1399,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -1491,7 +1414,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[1], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -1509,11 +1432,8 @@ describe('given the load domain connection using org id function', () => { }) describe('order direction is DESC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -1531,7 +1451,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -1546,7 +1466,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[0], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -1566,11 +1486,8 @@ describe('given the load domain connection using org id function', () => { describe('ordering on SPF_STATUS', () => { describe('order direction is ASC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -1588,7 +1505,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -1603,7 +1520,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[1], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -1621,11 +1538,8 @@ describe('given the load domain connection using org id function', () => { }) describe('order direction is DESC', () => { it('returns domains in order', async () => { - const domainLoader = loadDomainByKey({query}) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const domainLoader = loadDomainByKey({ query }) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -1643,7 +1557,7 @@ describe('given the load domain connection using org id function', () => { userKey: user._key, language, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, }) const domains = await connectionLoader({ orgId: org._id, @@ -1658,7 +1572,7 @@ describe('given the load domain connection using org id function', () => { node: { ...expectedDomains[0], claimTags: [], - hidden: false, + assetState: 'approved', }, }, ], @@ -1683,8 +1597,8 @@ describe('given the load domain connection using org id function', () => { i18n = setupI18n({ locale: 'en', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -1700,7 +1614,7 @@ describe('given the load domain connection using org id function', () => { query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -1729,7 +1643,7 @@ describe('given the load domain connection using org id function', () => { query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -1744,9 +1658,7 @@ describe('given the load domain connection using org id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `Passing both \`first\` and \`last\` to paginate the \`Domain\` connection is not supported.`, - ), + new Error(`Passing both \`first\` and \`last\` to paginate the \`Domain\` connection is not supported.`), ) } @@ -1762,7 +1674,7 @@ describe('given the load domain connection using org id function', () => { query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -1775,11 +1687,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` on the \`Domain\` connection cannot be less than zero.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` on the \`Domain\` connection cannot be less than zero.`)) } expect(consoleOutput).toEqual([ @@ -1793,7 +1701,7 @@ describe('given the load domain connection using org id function', () => { query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -1806,11 +1714,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` on the \`Domain\` connection cannot be less than zero.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` on the \`Domain\` connection cannot be less than zero.`)) } expect(consoleOutput).toEqual([ @@ -1826,7 +1730,7 @@ describe('given the load domain connection using org id function', () => { query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -1857,7 +1761,7 @@ describe('given the load domain connection using org id function', () => { query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -1886,14 +1790,12 @@ describe('given the load domain connection using org id function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDomainConnectionsByOrgId({ query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -1907,11 +1809,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -1923,14 +1821,12 @@ describe('given the load domain connection using org id function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDomainConnectionsByOrgId({ query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -1944,11 +1840,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -1963,15 +1855,13 @@ describe('given the load domain connection using org id function', () => { describe('given a database error', () => { describe('when gathering domain keys that are claimed by orgs that the user has affiliations to', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database Error Occurred.')) + const query = jest.fn().mockRejectedValue(new Error('Database Error Occurred.')) const connectionLoader = loadDomainConnectionsByOrgId({ query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -1984,9 +1874,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load domain(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load domain(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -2009,7 +1897,7 @@ describe('given the load domain connection using org id function', () => { query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -2022,9 +1910,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load domain(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load domain(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -2039,8 +1925,8 @@ describe('given the load domain connection using org id function', () => { i18n = setupI18n({ locale: 'fr', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -2056,7 +1942,7 @@ describe('given the load domain connection using org id function', () => { query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -2085,7 +1971,7 @@ describe('given the load domain connection using org id function', () => { query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -2100,9 +1986,7 @@ describe('given the load domain connection using org id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - "Passer à la fois `first` et `last` pour paginer la connexion `Domain` n'est pas supporté.", - ), + new Error("Passer à la fois `first` et `last` pour paginer la connexion `Domain` n'est pas supporté."), ) } @@ -2118,7 +2002,7 @@ describe('given the load domain connection using org id function', () => { query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -2131,11 +2015,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` sur la connexion `Domain` ne peut être inférieur à zéro.', - ), - ) + expect(err).toEqual(new Error('`first` sur la connexion `Domain` ne peut être inférieur à zéro.')) } expect(consoleOutput).toEqual([ @@ -2149,7 +2029,7 @@ describe('given the load domain connection using org id function', () => { query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -2162,11 +2042,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` sur la connexion `Domain` ne peut être inférieur à zéro.', - ), - ) + expect(err).toEqual(new Error('`last` sur la connexion `Domain` ne peut être inférieur à zéro.')) } expect(consoleOutput).toEqual([ @@ -2182,7 +2058,7 @@ describe('given the load domain connection using org id function', () => { query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -2213,7 +2089,7 @@ describe('given the load domain connection using org id function', () => { query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -2242,14 +2118,12 @@ describe('given the load domain connection using org id function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDomainConnectionsByOrgId({ query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -2264,9 +2138,7 @@ describe('given the load domain connection using org id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -2279,14 +2151,12 @@ describe('given the load domain connection using org id function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadDomainConnectionsByOrgId({ query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -2301,9 +2171,7 @@ describe('given the load domain connection using org id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -2319,15 +2187,13 @@ describe('given the load domain connection using org id function', () => { describe('given a database error', () => { describe('when gathering domain keys that are claimed by orgs that the user has affiliations to', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database Error Occurred.')) + const query = jest.fn().mockRejectedValue(new Error('Database Error Occurred.')) const connectionLoader = loadDomainConnectionsByOrgId({ query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -2340,11 +2206,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) domaine(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) domaine(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ @@ -2367,7 +2229,7 @@ describe('given the load domain connection using org id function', () => { query, userKey: user._key, cleanseInput, - auth: {loginRequired: true}, + auth: { loginRequired: true }, i18n, }) @@ -2380,11 +2242,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) domaine(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) domaine(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ diff --git a/api/src/domain/loaders/__tests__/load-domain-connections-by-user-id.test.js b/api/src/domain/loaders/__tests__/load-domain-connections-by-user-id.test.js index 653ed37031..a307b9b99a 100644 --- a/api/src/domain/loaders/__tests__/load-domain-connections-by-user-id.test.js +++ b/api/src/domain/loaders/__tests__/load-domain-connections-by-user-id.test.js @@ -1,5 +1,6 @@ import { stringify } from 'jest-matcher-utils' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/domain/loaders/__tests__/load-domain-tags-by-org-id.test.js b/api/src/domain/loaders/__tests__/load-domain-tags-by-org-id.test.js index 9777666985..805ad47915 100644 --- a/api/src/domain/loaders/__tests__/load-domain-tags-by-org-id.test.js +++ b/api/src/domain/loaders/__tests__/load-domain-tags-by-org-id.test.js @@ -1,12 +1,13 @@ -import {ensure, dbNameFromFile} from 'arango-tools' -import {setupI18n} from '@lingui/core' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' +import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' import frenchMessages from '../../../locale/fr/messages' -import {loadDomainTagsByOrgId} from '../index' +import { loadDomainTagsByOrgId } from '../index' import dbschema from '../../../../database.json' -const {DB_PASS: rootPass, DB_URL: url} = process.env +const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the load domain connection using org id function', () => { let query, drop, truncate, collections, user, org, domain, domainTwo, i18n @@ -25,7 +26,7 @@ describe('given the load domain connection using org id function', () => { describe('given a successful load', () => { beforeAll(async () => { - ;({query, drop, truncate, collections} = await ensure({ + ;({ query, drop, truncate, collections } = await ensure({ variables: { dbname: dbNameFromFile(__filename), username: 'root', @@ -141,8 +142,8 @@ describe('given the load domain connection using org id function', () => { const expectedStructure = { edges: [ - {id: 'CVE-2022-12345', severity: 'high'}, - {id: 'CVE-2022-54321', severity: 'low'}, + { id: 'CVE-2022-12345', severity: 'high' }, + { id: 'CVE-2022-54321', severity: 'low' }, ], totalCount: 2, } @@ -177,8 +178,8 @@ describe('given the load domain connection using org id function', () => { i18n = setupI18n({ locale: 'en', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -200,18 +201,14 @@ describe('given the load domain connection using org id function', () => { orgId: org._id, }) } catch (err) { - expect(err).toEqual( - new Error(`Unable to load domain(s). Please try again.`), - ) + expect(err).toEqual(new Error(`Unable to load domain(s). Please try again.`)) } }) }) describe('given a database error', () => { describe('when gathering domain keys that are claimed by orgs that the user has affiliations to', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database Error Occurred.')) + const query = jest.fn().mockRejectedValue(new Error('Database Error Occurred.')) const connectionLoader = loadDomainTagsByOrgId({ query, @@ -228,9 +225,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load domain(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load domain(s). Please try again.')) } }) }) diff --git a/api/src/domain/loaders/load-domain-connections-by-organizations-id.js b/api/src/domain/loaders/load-domain-connections-by-organizations-id.js index d843a093f8..62f7b14927 100644 --- a/api/src/domain/loaders/load-domain-connections-by-organizations-id.js +++ b/api/src/domain/loaders/load-domain-connections-by-organizations-id.js @@ -297,19 +297,14 @@ export const loadDomainConnectionsByOrgId = } let domainFilters = aql` - LET hidden = ( - FOR v, e IN 1..1 ANY domain._id claims - FILTER e._from == ${orgId} - RETURN e.hidden - )[0] - LET claimTags = ( + LET claimVals = ( FOR v, e IN 1..1 ANY domain._id claims FILTER e._from == ${orgId} LET translatedTags = ( FOR tag IN e.tags || [] RETURN TRANSLATE(${language}, tag) ) - RETURN translatedTags + RETURN { assetState: e.assetState, claimTags: translatedTags } )[0] ` if (typeof filters !== 'undefined') { @@ -370,12 +365,7 @@ export const loadDomainConnectionsByOrgId = FILTER domain.status.certificates ${comparison} ${filterValue} ` } else if (filterCategory === 'tags') { - if (filterValue === 'hidden') { - domainFilters = aql` - ${domainFilters} - FILTER hidden ${comparison} true - ` - } else if (filterValue === 'archived') { + if (filterValue === 'archived') { domainFilters = aql` ${domainFilters} FILTER domain.archived ${comparison} true @@ -400,12 +390,27 @@ export const loadDomainConnectionsByOrgId = ${domainFilters} FILTER domain.webScanPending ${comparison} true ` + } else if (filterValue === 'has-entrust-certificate') { + domainFilters = aql` + ${domainFilters} + FILTER domain.hasEntrustCertificate ${comparison} true + ` + } else if (filterValue === 'cve-detected') { + domainFilters = aql` + ${domainFilters} + FILTER domain.cveDetected ${comparison} true + ` } else { domainFilters = aql` ${domainFilters} - FILTER POSITION( claimTags, ${filterValue}) ${comparison} true + FILTER POSITION( claimVals.claimTags, ${filterValue}) ${comparison} true ` } + } else if (filterCategory === 'asset-state') { + domainFilters = aql` + ${domainFilters} + FILTER claimVals.assetState ${comparison} ${filterValue} + ` } }) } @@ -416,16 +421,13 @@ export const loadDomainConnectionsByOrgId = if (typeof search !== 'undefined' && search !== '') { search = cleanseInput(search) domainQuery = aql` - LET tokenArr = TOKENS(${search}, "space-delimiter-analyzer") - LET searchedDomains = ( - FOR tokenItem IN tokenArr - LET token = LOWER(tokenItem) - FOR domain IN domainSearch - SEARCH ANALYZER(domain.domain LIKE CONCAT("%", token, "%"), "space-delimiter-analyzer") + LET searchedDomains = ( + FOR domain IN domains + FILTER LOWER(domain.domain) LIKE LOWER(${search}) FILTER domain._key IN domainKeys RETURN MERGE({ id: domain._key, _type: "domain" }, domain) - ) - ` + ) + ` loopString = aql`FOR domain IN searchedDomains` totalCount = aql`LENGTH(searchedDomains)` } @@ -434,16 +436,11 @@ export const loadDomainConnectionsByOrgId = if (permission === 'super_admin') { showArchivedDomains = aql`` } - let showHiddenDomains = aql`FILTER e.hidden != true` - if (['super_admin', 'owner', 'admin', 'user'].includes(permission)) { - showHiddenDomains = aql`` - } let ownershipOrgsOnly = aql` LET claimKeys = ( FOR v, e IN 1..1 OUTBOUND ${orgId} claims OPTIONS {order: "bfs"} - ${showHiddenDomains} RETURN v._key ) ` @@ -453,7 +450,6 @@ export const loadDomainConnectionsByOrgId = LET claimKeys = ( FOR v, e IN 1..1 OUTBOUND ${orgId} ownership OPTIONS {order: "bfs"} - ${showHiddenDomains} RETURN v._key ) ` @@ -468,7 +464,6 @@ export const loadDomainConnectionsByOrgId = LET domainKeys = ( FOR v, e IN 1..1 OUTBOUND ${orgId} claims OPTIONS {order: "bfs"} - ${showHiddenDomains} RETURN v._key )` } else { @@ -515,7 +510,7 @@ export const loadDomainConnectionsByOrgId = SORT ${sortByField} ${limitTemplate} - RETURN MERGE({ id: domain._key, _type: "domain", "claimTags": claimTags, "hidden": hidden }, DOCUMENT(domain._id)) + RETURN MERGE({ id: domain._key, _type: "domain", "claimTags": claimVals.claimTags, "assetState": claimVals.assetState }, DOCUMENT(domain._id)) ) LET hasNextPage = (LENGTH( diff --git a/api/src/domain/loaders/load-domain-connections-by-user-id.js b/api/src/domain/loaders/load-domain-connections-by-user-id.js index bfc7cbc82a..36e974ada3 100644 --- a/api/src/domain/loaders/load-domain-connections-by-user-id.js +++ b/api/src/domain/loaders/load-domain-connections-by-user-id.js @@ -406,6 +406,16 @@ export const loadDomainConnectionsByUserId = ${domainFilters} FILTER domain.webScanPending ${comparison} true ` + } else if (filterValue === 'has-entrust-certificate') { + domainFilters = aql` + ${domainFilters} + FILTER domain.hasEntrustCertificate ${comparison} true + ` + } else if (filterValue === 'cve-detected') { + domainFilters = aql` + ${domainFilters} + FILTER domain.cveDetected ${comparison} true + ` } } }) @@ -488,14 +498,11 @@ export const loadDomainConnectionsByUserId = if (typeof search !== 'undefined' && search !== '') { search = cleanseInput(search) domainQuery = aql` - LET tokenArr = TOKENS(${search}, "space-delimiter-analyzer") LET searchedDomains = ( - FOR tokenItem in tokenArr - LET token = LOWER(tokenItem) - FOR domain IN domainSearch - SEARCH ANALYZER(domain.domain LIKE CONCAT("%", token, "%"), "space-delimiter-analyzer") - FILTER domain IN collectedDomains - RETURN domain + FOR domain IN domains + FILTER LOWER(domain.domain) LIKE LOWER(${search}) + FILTER domain IN collectedDomains + RETURN domain ) ` loopString = aql`FOR domain IN searchedDomains` diff --git a/api/src/domain/mutations/__tests__/add-organizations-domains.test.js b/api/src/domain/mutations/__tests__/add-organizations-domains.test.js index 6b17930814..7969ba2e87 100644 --- a/api/src/domain/mutations/__tests__/add-organizations-domains.test.js +++ b/api/src/domain/mutations/__tests__/add-organizations-domains.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' @@ -120,7 +121,6 @@ describe('given the addOrganizationsDomains mutation', () => { input: { orgId: "${toGlobalId('organizations', org._key)}" domains: ["test.domain.gov", "test.domain2.gov"] - hideNewDomains: false tagNewDomains: false tagStagingDomains: false audit: false @@ -190,7 +190,6 @@ describe('given the addOrganizationsDomains mutation', () => { input: { orgId: "${toGlobalId('organizations', org._key)}" domains: ["test.domain.gov", "test.domain2.gov"] - hideNewDomains: false tagNewDomains: false tagStagingDomains: false audit: true @@ -337,7 +336,6 @@ describe('given the addOrganizationsDomains mutation', () => { input: { orgId: "${toGlobalId('organizations', org._key)}" domains: ["test.domain.gov", "test.domain2.gov"] - hideNewDomains: false tagNewDomains: false tagStagingDomains: false audit: false diff --git a/api/src/domain/mutations/__tests__/create-domain.test.js b/api/src/domain/mutations/__tests__/create-domain.test.js index a5856c382a..c0daed350b 100644 --- a/api/src/domain/mutations/__tests__/create-domain.test.js +++ b/api/src/domain/mutations/__tests__/create-domain.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' @@ -144,6 +145,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', org._key)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -304,6 +306,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', org._key)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -440,6 +443,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', org._key)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -616,6 +620,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', secondOrg._key)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -755,6 +760,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', secondOrg._key)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -895,6 +901,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', secondOrg._key)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -1045,7 +1052,8 @@ describe('create a domain', () => { source: ` mutation { createDomain( - input: { orgId: "b3JnYW5pemF0aW9uOjE=", domain: "test.gc.ca" } + input: { orgId: "b3JnYW5pemF0aW9uOjE=", domain: "test.gc.ca" + assetState: APPROVED } ) { result { ... on Domain { @@ -1150,6 +1158,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -1257,6 +1266,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -1367,6 +1377,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -1467,6 +1478,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -1567,6 +1579,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -1674,6 +1687,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -1776,6 +1790,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -1885,6 +1900,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -1992,6 +2008,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -2105,6 +2122,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -2227,7 +2245,8 @@ describe('create a domain', () => { source: ` mutation { createDomain( - input: { orgId: "b3JnYW5pemF0aW9uOjE=", domain: "test.gc.ca" } + input: { orgId: "b3JnYW5pemF0aW9uOjE=", domain: "test.gc.ca" + assetState: APPROVED } ) { result { ... on Domain { @@ -2332,6 +2351,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -2440,6 +2460,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -2550,6 +2571,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -2650,6 +2672,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -2750,6 +2773,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -2857,6 +2881,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -2959,6 +2984,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -3068,6 +3094,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -3175,6 +3202,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { @@ -3288,6 +3316,7 @@ describe('create a domain', () => { input: { orgId: "${toGlobalId('organization', 123)}" domain: "test.gc.ca" + assetState: APPROVED } ) { result { diff --git a/api/src/domain/mutations/__tests__/favourite-domain.test.js b/api/src/domain/mutations/__tests__/favourite-domain.test.js index 0dbf09276a..2310b05235 100644 --- a/api/src/domain/mutations/__tests__/favourite-domain.test.js +++ b/api/src/domain/mutations/__tests__/favourite-domain.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/domain/mutations/__tests__/remove-domain.test.js b/api/src/domain/mutations/__tests__/remove-domain.test.js index 1f266358f2..0bdbbf2d6c 100644 --- a/api/src/domain/mutations/__tests__/remove-domain.test.js +++ b/api/src/domain/mutations/__tests__/remove-domain.test.js @@ -1,5 +1,6 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/domain/mutations/__tests__/remove-organizations-domains.test.js b/api/src/domain/mutations/__tests__/remove-organizations-domains.test.js index 74a69df36b..cf385dc7cc 100644 --- a/api/src/domain/mutations/__tests__/remove-organizations-domains.test.js +++ b/api/src/domain/mutations/__tests__/remove-organizations-domains.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/domain/mutations/__tests__/unfavourite-domain.test.js b/api/src/domain/mutations/__tests__/unfavourite-domain.test.js index 365525c139..a55c50e47d 100644 --- a/api/src/domain/mutations/__tests__/unfavourite-domain.test.js +++ b/api/src/domain/mutations/__tests__/unfavourite-domain.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/domain/mutations/__tests__/update-domain.test.js b/api/src/domain/mutations/__tests__/update-domain.test.js index dd3c9f74ea..943af61df3 100644 --- a/api/src/domain/mutations/__tests__/update-domain.test.js +++ b/api/src/domain/mutations/__tests__/update-domain.test.js @@ -1,5 +1,6 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/domain/mutations/add-organizations-domains.js b/api/src/domain/mutations/add-organizations-domains.js index 58c330485f..b6b7c72b5e 100644 --- a/api/src/domain/mutations/add-organizations-domains.js +++ b/api/src/domain/mutations/add-organizations-domains.js @@ -18,10 +18,6 @@ export const addOrganizationsDomains = new mutationWithClientMutationId({ type: new GraphQLNonNull(new GraphQLList(Domain)), description: 'Url that you would like to be added to the database.', }, - hideNewDomains: { - type: GraphQLBoolean, - description: 'New domains will be hidden.', - }, tagNewDomains: { type: GraphQLBoolean, description: 'New domains will be tagged with NEW.', @@ -72,13 +68,6 @@ export const addOrganizationsDomains = new mutationWithClientMutationId({ domains = [] } - let hideNewDomains - if (typeof args.hideNewDomains !== 'undefined') { - hideNewDomains = args.hideNewDomains - } else { - hideNewDomains = false - } - let tagNewDomains if (typeof args.tagNewDomains !== 'undefined') { tagNewDomains = args.tagNewDomains @@ -142,13 +131,6 @@ export const addOrganizationsDomains = new mutationWithClientMutationId({ newValue: tags, }) } - if (hideNewDomains) { - updatedProperties.push({ - name: 'hidden', - oldValue: null, - newValue: hideNewDomains, - }) - } let domainCount = 0 @@ -248,7 +230,6 @@ export const addOrganizationsDomains = new mutationWithClientMutationId({ _from: ${org._id}, _to: ${insertedDomain._id}, tags: ${tags}, - hidden: ${hideNewDomains} } INTO claims `, ) @@ -266,7 +247,6 @@ export const addOrganizationsDomains = new mutationWithClientMutationId({ _from: ${org._id}, _to: ${checkDomain._id}, tags: ${tags}, - hidden: ${hideNewDomains} } INTO claims `, ) diff --git a/api/src/domain/mutations/create-domain.js b/api/src/domain/mutations/create-domain.js index c3b329303c..ad0ccfe57d 100644 --- a/api/src/domain/mutations/create-domain.js +++ b/api/src/domain/mutations/create-domain.js @@ -6,7 +6,7 @@ import { createDomainUnion } from '../unions' import { Domain } from '../../scalars' import { logActivity } from '../../audit-logs/mutations/log-activity' import { inputTag } from '../inputs/domain-tag' -import { OutsideDomainCommentEnum } from '../../enums' +import { AssetStateEnums } from '../../enums' export const createDomain = new mutationWithClientMutationId({ name: 'CreateDomain', @@ -24,17 +24,13 @@ export const createDomain = new mutationWithClientMutationId({ description: 'List of labelled tags users have applied to the domain.', type: new GraphQLList(inputTag), }, - hidden: { - description: "Value that determines if the domain is excluded from an organization's score.", - type: GraphQLBoolean, - }, archived: { description: 'Value that determines if the domain is excluded from the scanning process.', type: GraphQLBoolean, }, - outsideComment: { - description: 'Comment describing reason for adding out-of-scope domain.', - type: OutsideDomainCommentEnum, + assetState: { + description: 'Value that determines how the domain relates to the organization.', + type: new GraphQLNonNull(AssetStateEnums), }, }), outputFields: () => ({ @@ -84,29 +80,11 @@ export const createDomain = new mutationWithClientMutationId({ archived = false } - let hidden - if (typeof args.hidden !== 'undefined') { - hidden = args.hidden - } else { - hidden = false - } - - let outsideComment - if (typeof args.outsideComment !== 'undefined') { - outsideComment = cleanseInput(args.outsideComment) + let assetState + if (typeof args.assetState !== 'undefined') { + assetState = cleanseInput(args.assetState) } else { - outsideComment = '' - } - - if (tags?.find(({ en }) => en === 'OUTSIDE')) { - if (outsideComment === '') { - console.warn(`User: ${userKey} attempted to create a domain with the OUTSIDE tag without providing a comment.`) - return { - _type: 'error', - code: 400, - description: i18n._(t`Please provide a comment when adding an outside domain.`), - } - } + assetState = '' } // Check to see if org exists @@ -229,8 +207,7 @@ export const createDomain = new mutationWithClientMutationId({ _from: ${org._id}, _to: ${insertedDomain._id}, tags: ${tags}, - hidden: ${hidden}, - outsideComment: ${outsideComment}, + assetState: ${assetState}, firstSeen: ${new Date().toISOString()}, } INTO claims `, @@ -262,11 +239,11 @@ export const createDomain = new mutationWithClientMutationId({ }) } - if (typeof hidden !== 'undefined') { + if (typeof assetState !== 'undefined') { updatedProperties.push({ - name: 'hidden', + name: 'assetState', oldValue: null, - newValue: hidden, + newValue: assetState, }) } @@ -289,12 +266,11 @@ export const createDomain = new mutationWithClientMutationId({ }, // name of resource being acted upon resourceType: 'domain', // user, org, domain }, - reason: outsideComment !== '' ? outsideComment : null, }) try { await publish({ - channel: `domains.${returnDomain._key}`, + channel: 'scans.requests', msg: { domain: returnDomain.domain, domain_key: returnDomain._key, @@ -309,7 +285,7 @@ export const createDomain = new mutationWithClientMutationId({ try { await publish({ - channel: `domains.${returnDomain._key}.easm`, + channel: 'scans.add_domain_to_easm', msg: { domain: returnDomain.domain, domain_key: returnDomain._key, @@ -327,7 +303,6 @@ export const createDomain = new mutationWithClientMutationId({ claimTags: tags.map((tag) => { return tag[language] }), - hidden, } }, }) diff --git a/api/src/domain/mutations/request-discovery.js b/api/src/domain/mutations/request-discovery.js index 5815b52b30..79636aaed3 100644 --- a/api/src/domain/mutations/request-discovery.js +++ b/api/src/domain/mutations/request-discovery.js @@ -99,7 +99,7 @@ export const requestDiscovery = new mutationWithClientMutationId({ } await publish({ - channel: `domains.${domain._key}.discovery`, + channel: `scans.discovery`, msg: { domain: domain.domain, orgId: org._id, diff --git a/api/src/domain/mutations/request-scan.js b/api/src/domain/mutations/request-scan.js index 68c5444ec8..a395602d77 100644 --- a/api/src/domain/mutations/request-scan.js +++ b/api/src/domain/mutations/request-scan.js @@ -126,11 +126,10 @@ export const requestScan = new mutationWithClientMutationId({ } await publish({ - channel: `domains.${domain._key}`, + channel: 'scans.requests', msg: { domain: domain.domain, domain_key: domain._key, - selectors: domain.selectors ? domain.selectors : [], hash: domain.hash, user_key: null, // only used for One Time Scans shared_id: null, // only used for One Time Scans diff --git a/api/src/domain/mutations/update-domain.js b/api/src/domain/mutations/update-domain.js index b2c37c35a1..fe6cf970df 100644 --- a/api/src/domain/mutations/update-domain.js +++ b/api/src/domain/mutations/update-domain.js @@ -6,7 +6,7 @@ import { updateDomainUnion } from '../unions' import { Domain } from '../../scalars' import { logActivity } from '../../audit-logs/mutations/log-activity' import { inputTag } from '../inputs/domain-tag' -import { OutsideDomainCommentEnum } from '../../enums' +import { AssetStateEnums } from '../../enums' export const updateDomain = new mutationWithClientMutationId({ name: 'UpdateDomain', @@ -28,22 +28,18 @@ export const updateDomain = new mutationWithClientMutationId({ description: 'List of labelled tags users have applied to the domain.', type: new GraphQLList(inputTag), }, - hidden: { - description: "Value that determines if the domain is excluded from an organization's score.", - type: GraphQLBoolean, - }, archived: { description: 'Value that determines if the domain is excluded from the scanning process.', type: GraphQLBoolean, }, - outsideComment: { - description: 'Comment describing reason for adding out-of-scope domain.', - type: OutsideDomainCommentEnum, - }, ignoreRua: { description: 'Boolean value that determines if the domain should ignore rua reports.', type: GraphQLBoolean, }, + assetState: { + description: 'Value that determines how the domain relates to the organization.', + type: AssetStateEnums, + }, }), outputFields: () => ({ result: { @@ -90,29 +86,11 @@ export const updateDomain = new mutationWithClientMutationId({ archived = null } - let hidden - if (typeof args.hidden !== 'undefined') { - hidden = args.hidden + let assetState + if (typeof args.assetState !== 'undefined') { + assetState = cleanseInput(args.assetState) } else { - hidden = null - } - - let outsideComment - if (typeof args.outsideComment !== 'undefined') { - outsideComment = cleanseInput(args.outsideComment) - } else { - outsideComment = '' - } - - if (tags?.find(({ en }) => en === 'OUTSIDE')) { - if (outsideComment === '') { - console.warn(`User: ${userKey} attempted to create a domain with the OUTSIDE tag without providing a comment.`) - return { - _type: 'error', - code: 400, - description: i18n._(t`Please provide a comment when adding an outside domain.`), - } - } + assetState = '' } // Check to see if domain exists @@ -233,8 +211,8 @@ export const updateDomain = new mutationWithClientMutationId({ const claimToInsert = { tags: tags || claim?.tags, - hidden: typeof hidden !== 'undefined' ? hidden : claim?.hidden, firstSeen: typeof claim?.firstSeen === 'undefined' ? new Date().toISOString() : claim?.firstSeen, + assetState: assetState || claim?.assetState, } try { @@ -280,19 +258,19 @@ export const updateDomain = new mutationWithClientMutationId({ }) } - if (typeof tags !== 'undefined' && JSON.stringify(claim.tags) !== JSON.stringify(tags)) { + if (typeof assetState !== 'undefined') { updatedProperties.push({ - name: 'tags', - oldValue: claim.tags, - newValue: tags, + name: 'assetState', + oldValue: claim.assetState, + newValue: assetState, }) } - if (typeof hidden !== 'undefined') { + if (typeof tags !== 'undefined' && JSON.stringify(claim.tags) !== JSON.stringify(tags)) { updatedProperties.push({ - name: 'hidden', - oldValue: claim?.hidden, - newValue: hidden, + name: 'tags', + oldValue: claim.tags, + newValue: tags, }) } @@ -316,7 +294,6 @@ export const updateDomain = new mutationWithClientMutationId({ resourceType: 'domain', // user, org, domain updatedProperties, }, - reason: outsideComment !== '' ? outsideComment : null, }) } @@ -346,7 +323,7 @@ export const updateDomain = new mutationWithClientMutationId({ claimTags: claimToInsert.tags.map((tag) => { return tag[language] }), - hidden, + assetState, } }, }) diff --git a/api/src/domain/objects/domain.js b/api/src/domain/objects/domain.js index d5659bd9b4..b954f24ce4 100644 --- a/api/src/domain/objects/domain.js +++ b/api/src/domain/objects/domain.js @@ -3,7 +3,7 @@ import { GraphQLBoolean, GraphQLInt, GraphQLList, GraphQLNonNull, GraphQLObjectT import { connectionArgs, globalIdField } from 'graphql-relay' import { domainStatus } from './domain-status' -import { PeriodEnums } from '../../enums' +import { AssetStateEnums, DomainTagLabel, PeriodEnums } from '../../enums' import { nodeInterface } from '../../node' import { Domain, Selectors, Year } from '../../scalars' import { dmarcSummaryType } from '../../dmarc-summaries/objects' @@ -361,14 +361,9 @@ export const domainType = new GraphQLObjectType({ }, claimTags: { description: 'List of labelled tags users of an organization have applied to the claimed domain.', - type: new GraphQLList(GraphQLString), + type: new GraphQLList(DomainTagLabel), resolve: ({ claimTags }) => claimTags, }, - hidden: { - description: "Value that determines if a domain is excluded from an organization's results.", - type: GraphQLBoolean, - resolve: ({ hidden }) => hidden, - }, userHasPermission: { description: 'Value that determines if a user is affiliated with a domain, whether through organization affiliation, verified organization network affiliation, or through super admin status.', @@ -384,6 +379,21 @@ export const domainType = new GraphQLObjectType({ type: GraphQLBoolean, resolve: ({ ignoreRua }) => ignoreRua, }, + assetState: { + description: 'Value that determines if a domain is considered an asset.', + type: AssetStateEnums, + resolve: ({ assetState }) => assetState, + }, + hasEntrustCertificate: { + type: GraphQLBoolean, + description: `Whether or not the certificate chain contains an Entrust certificate.`, + resolve: ({ hasEntrustCertificate }) => hasEntrustCertificate, + }, + cveDetected: { + type: GraphQLBoolean, + description: `Whether or not a CVE has been detected in the domain's additional findings.`, + resolve: ({ cveDetected }) => cveDetected, + }, }), interfaces: [nodeInterface], description: 'Domain object containing information for a given domain.', diff --git a/api/src/domain/queries/__tests__/find-domain-by-domain.test.js b/api/src/domain/queries/__tests__/find-domain-by-domain.test.js index 02f664a2ff..40559ea2f9 100644 --- a/api/src/domain/queries/__tests__/find-domain-by-domain.test.js +++ b/api/src/domain/queries/__tests__/find-domain-by-domain.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/domain/queries/__tests__/find-my-domains.test.js b/api/src/domain/queries/__tests__/find-my-domains.test.js index b43533afbd..92aaa48f87 100644 --- a/api/src/domain/queries/__tests__/find-my-domains.test.js +++ b/api/src/domain/queries/__tests__/find-my-domains.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/enums/asset-state.js b/api/src/enums/asset-state.js new file mode 100644 index 0000000000..6fa8921c93 --- /dev/null +++ b/api/src/enums/asset-state.js @@ -0,0 +1,28 @@ +import { GraphQLEnumType } from 'graphql' + +export const AssetStateEnums = new GraphQLEnumType({ + name: 'AssetStateEnums', + values: { + APPROVED: { + value: 'approved', + description: 'An asset confirmed to belong to the organization.', + }, + DEPENDENCY: { + value: 'dependency', + description: 'An asset that is owned by a third party and supports the operation of organization-owned assets.', + }, + MONITOR_ONLY: { + value: 'monitor-only', + description: 'An asset that is relevant to the organization but is not a direct part of the attack surface.', + }, + CANDIDATE: { + value: 'candidate', + description: 'An asset that is suspected to belong to the organization but has not been confirmed.', + }, + REQUIRES_INVESTIGATION: { + value: 'requires-investigation', + description: 'An asset that requires further investigation to determine its relationship to the organization.', + }, + }, + description: "An enum used to describe how an asset relates to an organization's attack surface.", +}) diff --git a/api/src/enums/domain-order-field.js b/api/src/enums/domain-order-field.js index 98ec17b492..83376da03a 100644 --- a/api/src/enums/domain-order-field.js +++ b/api/src/enums/domain-order-field.js @@ -52,5 +52,9 @@ export const DomainOrderField = new GraphQLEnumType({ value: 'tags', description: 'Order domains by tags.', }, + ASSET_STATE: { + value: 'asset-state', + description: 'Order domains by asset state.', + }, }, }) diff --git a/api/src/enums/domain-tag-label.js b/api/src/enums/domain-tag-label.js index 896d61102d..5b870257bc 100644 --- a/api/src/enums/domain-tag-label.js +++ b/api/src/enums/domain-tag-label.js @@ -39,10 +39,6 @@ export const DomainTagLabel = new GraphQLEnumType({ value: 'INACTIF', description: 'French label for tagging domains that are not active.', }, - HIDDEN: { - value: 'hidden', - description: 'English label for tagging domains that are hidden.', - }, ARCHIVED: { value: 'archived', description: 'English label for tagging domains that are archived.', @@ -63,13 +59,13 @@ export const DomainTagLabel = new GraphQLEnumType({ value: 'scan-pending', description: 'Label for tagging domains that have a pending web scan.', }, - OUTSIDE: { - value: 'OUTSIDE', - description: 'English label for tagging domains that are outside the scope of the project.', + HAS_ENTRUST_CERTIFICATE: { + value: 'has-entrust-certificate', + description: 'Label for tagging domains that have an Entrust certificate.', }, - EXTERIEUR: { - value: 'EXTÉRIEUR', - description: 'French label for tagging domains that are outside the scope of the project.', + CVE_DETECTED: { + value: 'cve-detected', + description: 'Label for tagging domains that have vulnerabilities.', }, }, description: 'An enum used to assign and test user-generated domain tags', diff --git a/api/src/enums/index.js b/api/src/enums/index.js index 41ea86414b..16ba803704 100644 --- a/api/src/enums/index.js +++ b/api/src/enums/index.js @@ -1,5 +1,6 @@ export * from './affiliation-org-order-field' export * from './affiliation-user-order-field' +export * from './asset-state' export * from './user-order-field' export * from './dkim-order-field' export * from './dkim-result-order-field' @@ -28,4 +29,3 @@ export * from './tfa-send-method' export * from './verified-domain-order-field' export * from './verified-organization-order-field' export * from './web-order-field' -export * from './outside-domain-comment' diff --git a/api/src/enums/outside-domain-comment.js b/api/src/enums/outside-domain-comment.js deleted file mode 100644 index ccc7ba7fcf..0000000000 --- a/api/src/enums/outside-domain-comment.js +++ /dev/null @@ -1,20 +0,0 @@ -import { GraphQLEnumType } from 'graphql' - -export const OutsideDomainCommentEnum = new GraphQLEnumType({ - name: 'OutsideDomainCommentEnum', - values: { - INVESTMENT: { - value: 'investment', - description: 'Organization is invested in the outside domain.', - }, - OWNERSHIP: { - value: 'ownership', - description: 'Organization owns this domain, but it is outside the allowed scope.', - }, - OTHER: { - value: 'other', - description: 'Other reason.', - }, - }, - description: 'Reason why an outside domain was added to the organization.', -}) diff --git a/api/src/guidance-tag/loaders/index.js b/api/src/guidance-tag/loaders/index.js index ea70fd106b..d57c07c59c 100644 --- a/api/src/guidance-tag/loaders/index.js +++ b/api/src/guidance-tag/loaders/index.js @@ -10,3 +10,4 @@ export * from './load-spf-guidance-tags' export * from './load-spf-guidance-tags-connections' export * from './load-ssl-guidance-tags' export * from './load-ssl-guidance-tags-connections' +export * from './load-guidance-tags' diff --git a/api/src/guidance-tag/loaders/load-guidance-tags.js b/api/src/guidance-tag/loaders/load-guidance-tags.js new file mode 100644 index 0000000000..3245fa6312 --- /dev/null +++ b/api/src/guidance-tag/loaders/load-guidance-tags.js @@ -0,0 +1,40 @@ +import { t } from '@lingui/macro' + +export const loadGuidanceTagByTagId = + ({ query, userKey, i18n, language }) => + async ({ tags = [] }) => { + let cursor + try { + cursor = await query` + WITH guidanceTags + FOR tag IN guidanceTags + FILTER tag._key IN ${tags} + RETURN MERGE( + { + _id: tag._id, + _key: tag._key, + _rev: tag._rev, + _type: "guidanceTag", + id: tag._key, + tagId: tag._key + }, + TRANSLATE(${language}, tag) + ) + ` + } catch (err) { + console.error(`Database error occurred when user: ${userKey} running loadGuidanceTagByTagId: ${err}`) + throw new Error(i18n._(t`Unable to find guidance tag(s). Please try again.`)) + } + + const tagMap = {} + try { + await cursor.forEach((tag) => { + tagMap[tag._key] = tag + }) + } catch (err) { + console.error(`Cursor error occurred when user: ${userKey} running loadGuidanceTagByTagId: ${err}`) + throw new Error(i18n._(t`Unable to find guidance tag(s). Please try again.`)) + } + + return tags.map((tag) => tagMap[tag]) + } diff --git a/api/src/initialize-loaders.js b/api/src/initialize-loaders.js index 5a77472c7c..348942348c 100644 --- a/api/src/initialize-loaders.js +++ b/api/src/initialize-loaders.js @@ -38,6 +38,7 @@ import { loadSpfGuidanceTagConnectionsByTagId, loadSslGuidanceTagByTagId, loadSslGuidanceTagConnectionsByTagId, + loadGuidanceTagByTagId, } from './guidance-tag/loaders' import { loadOrgByKey, @@ -225,6 +226,12 @@ export function initializeLoaders({ query, db, userKey, i18n, language, cleanseI i18n, language, }), + loadGuidanceTagByTagId: loadGuidanceTagByTagId({ + query, + userKey, + i18n, + language, + }), loadHttpsGuidanceTagByTagId: loadHttpsGuidanceTagByTagId({ query, userKey, diff --git a/api/src/locale/en/messages.js b/api/src/locale/en/messages.js index b1ad2ca89a..adb502bfb3 100644 --- a/api/src/locale/en/messages.js +++ b/api/src/locale/en/messages.js @@ -1 +1 @@ -/*eslint-disable*/module.exports={messages:{"Authentication error. Please sign in.":"Authentication error. Please sign in.","Cannot query affiliations on organization without admin permission or higher.":"Cannot query affiliations on organization without admin permission or higher.","Cannot query audit logs on organization without admin permission or higher.":"Cannot query audit logs on organization without admin permission or higher.","Cannot query dns scan results without permission.":"Cannot query dns scan results without permission.","Cannot query domain selectors without permission.":"Cannot query domain selectors without permission.","Cannot query web scan results without permission.":"Cannot query web scan results without permission.","Email already in use.":"Email already in use.","Error while requesting scan. Please try again.":"Error while requesting scan. Please try again.","If an account with this username is found, a password reset link will be found in your inbox.":"If an account with this username is found, a password reset link will be found in your inbox.","If an account with this username is found, an email verification link will be found in your inbox.":"If an account with this username is found, an email verification link will be found in your inbox.","Incorrect TFA code. Please sign in again.":"Incorrect TFA code. Please sign in again.","Incorrect token value. Please request a new email.":"Incorrect token value. Please request a new email.","Incorrect username or password. Please try again.":"Incorrect username or password. Please try again.","Invalid token, please sign in.":"Invalid token, please sign in.","New passwords do not match.":"New passwords do not match.","No organization with the provided slug could be found.":"No organization with the provided slug could be found.","No verified domain with the provided domain could be found.":"No verified domain with the provided domain could be found.","No verified organization with the provided slug could be found.":"No verified organization with the provided slug could be found.","Organization has already been verified.":"Organization has already been verified.","Organization name already in use, please choose another and try again.":"Organization name already in use, please choose another and try again.","Organization name already in use. Please try again with a different name.":"Organization name already in use. Please try again with a different name.","Ownership check error. Unable to request domain information.":"Ownership check error. Unable to request domain information.","Passing both `first` and `last` to paginate the `Affiliation` connection is not supported.":"Passing both `first` and `last` to paginate the `Affiliation` connection is not supported.","Passing both `first` and `last` to paginate the `DKIMResults` connection is not supported.":"Passing both `first` and `last` to paginate the `DKIMResults` connection is not supported.","Passing both `first` and `last` to paginate the `DKIM` connection is not supported.":"Passing both `first` and `last` to paginate the `DKIM` connection is not supported.","Passing both `first` and `last` to paginate the `DMARC` connection is not supported.":"Passing both `first` and `last` to paginate the `DMARC` connection is not supported.","Passing both `first` and `last` to paginate the `DkimFailureTable` connection is not supported.":"Passing both `first` and `last` to paginate the `DkimFailureTable` connection is not supported.","Passing both `first` and `last` to paginate the `DmarcFailureTable` connection is not supported.":"Passing both `first` and `last` to paginate the `DmarcFailureTable` connection is not supported.","Passing both `first` and `last` to paginate the `DmarcSummaries` connection is not supported.":"Passing both `first` and `last` to paginate the `DmarcSummaries` connection is not supported.","Passing both `first` and `last` to paginate the `Domain` connection is not supported.":"Passing both `first` and `last` to paginate the `Domain` connection is not supported.","Passing both `first` and `last` to paginate the `FullPassTable` connection is not supported.":"Passing both `first` and `last` to paginate the `FullPassTable` connection is not supported.","Passing both `first` and `last` to paginate the `GuidanceTag` connection is not supported.":"Passing both `first` and `last` to paginate the `GuidanceTag` connection is not supported.","Passing both `first` and `last` to paginate the `HTTPS` connection is not supported.":"Passing both `first` and `last` to paginate the `HTTPS` connection is not supported.","Passing both `first` and `last` to paginate the `Log` connection is not supported.":"Passing both `first` and `last` to paginate the `Log` connection is not supported.","Passing both `first` and `last` to paginate the `Organization` connection is not supported.":"Passing both `first` and `last` to paginate the `Organization` connection is not supported.","Passing both `first` and `last` to paginate the `SPF` connection is not supported.":"Passing both `first` and `last` to paginate the `SPF` connection is not supported.","Passing both `first` and `last` to paginate the `SSL` connection is not supported.":"Passing both `first` and `last` to paginate the `SSL` connection is not supported.","Passing both `first` and `last` to paginate the `SpfFailureTable` connection is not supported.":"Passing both `first` and `last` to paginate the `SpfFailureTable` connection is not supported.","Passing both `first` and `last` to paginate the `User` connection is not supported.":"Passing both `first` and `last` to paginate the `User` connection is not supported.","Passing both `first` and `last` to paginate the `VerifiedDomain` connection is not supported.":"Passing both `first` and `last` to paginate the `VerifiedDomain` connection is not supported.","Passing both `first` and `last` to paginate the `VerifiedOrganization` connection is not supported.":"Passing both `first` and `last` to paginate the `VerifiedOrganization` connection is not supported.","Password does not meet requirements.":"Password does not meet requirements.","Password was successfully reset.":"Password was successfully reset.","Password was successfully updated.":"Password was successfully updated.","Passwords do not match.":"Passwords do not match.","Permission Denied: Could not retrieve specified organization.":"Permission Denied: Could not retrieve specified organization.","Permission Denied: Multi-factor authentication is required for admin accounts":"Permission Denied: Multi-factor authentication is required for admin accounts","Permission Denied: Please contact org owner to transfer ownership.":"Permission Denied: Please contact org owner to transfer ownership.","Permission Denied: Please contact organization admin for help with archiving domains.":"Permission Denied: Please contact organization admin for help with archiving domains.","Permission Denied: Please contact organization admin for help with removing domain.":"Permission Denied: Please contact organization admin for help with removing domain.","Permission Denied: Please contact organization admin for help with removing domains.":"Permission Denied: Please contact organization admin for help with removing domains.","Permission Denied: Please contact organization admin for help with removing organization.":"Permission Denied: Please contact organization admin for help with removing organization.","Permission Denied: Please contact organization admin for help with removing users.":"Permission Denied: Please contact organization admin for help with removing users.","Permission Denied: Please contact organization admin for help with updating organization.":"Permission Denied: Please contact organization admin for help with updating organization.","Permission Denied: Please contact organization admin for help with updating user roles.":"Permission Denied: Please contact organization admin for help with updating user roles.","Permission Denied: Please contact organization admin for help with user invitations.":"Permission Denied: Please contact organization admin for help with user invitations.","Permission Denied: Please contact organization admin for help with user role changes.":"Permission Denied: Please contact organization admin for help with user role changes.","Permission Denied: Please contact organization user for help with creating domain.":"Permission Denied: Please contact organization user for help with creating domain.","Permission Denied: Please contact organization user for help with creating domains.":"Permission Denied: Please contact organization user for help with creating domains.","Permission Denied: Please contact organization user for help with retrieving this domain.":"Permission Denied: Please contact organization user for help with retrieving this domain.","Permission Denied: Please contact organization user for help with scanning this domain.":"Permission Denied: Please contact organization user for help with scanning this domain.","Permission Denied: Please contact organization user for help with updating this domain.":"Permission Denied: Please contact organization user for help with updating this domain.","Permission Denied: Please contact super admin for help with archiving organization.":"Permission Denied: Please contact super admin for help with archiving organization.","Permission Denied: Please contact super admin for help with removing domain.":"Permission Denied: Please contact super admin for help with removing domain.","Permission Denied: Please contact super admin for help with removing organization.":"Permission Denied: Please contact super admin for help with removing organization.","Permission Denied: Please contact super admin for help with scanning this domain.":"Permission Denied: Please contact super admin for help with scanning this domain.","Permission Denied: Please contact super admin for help with verifying this organization.":"Permission Denied: Please contact super admin for help with verifying this organization.","Permission check error. Unable to request domain information.":"Permission check error. Unable to request domain information.","Permission error, not an admin for this user.":"Permission error, not an admin for this user.","Permission error: Unable to close other user's account.":"Permission error: Unable to close other user's account.","Permissions error. You do not have sufficient permissions to access this data.":"Permissions error. You do not have sufficient permissions to access this data.","Phone number has been successfully removed.":"Phone number has been successfully removed.","Phone number has been successfully set, you will receive a verification text message shortly.":"Phone number has been successfully set, you will receive a verification text message shortly.","Please provide a comment when adding an outside domain.":"Please provide a comment when adding an outside domain.","Profile successfully updated.":"Profile successfully updated.","Requesting `{amount}` records on the `Affiliation` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `Affiliation` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `DkimFailureTable` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `DkimFailureTable` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `DmarcFailureTable` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `DmarcFailureTable` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `DmarcSummaries` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `DmarcSummaries` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `Domain` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `Domain` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `FullPassTable` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `FullPassTable` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `GuidanceTag` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `GuidanceTag` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `Log` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `Log` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `Organization` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `Organization` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `SpfFailureTable` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `SpfFailureTable` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `User` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `User` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `VerifiedDomain` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `VerifiedDomain` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `VerifiedOrganization` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `VerifiedOrganization` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting {amount} records on the `DKIMResults` connection exceeds the `{argSet}` limit of 100 records.":["Requesting ",["amount"]," records on the `DKIMResults` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting {amount} records on the `DKIM` connection exceeds the `{argSet}` limit of 100 records.":["Requesting ",["amount"]," records on the `DKIM` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting {amount} records on the `DMARC` connection exceeds the `{argSet}` limit of 100 records.":["Requesting ",["amount"]," records on the `DMARC` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting {amount} records on the `HTTPS` connection exceeds the `{argSet}` limit of 100 records.":["Requesting ",["amount"]," records on the `HTTPS` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting {amount} records on the `SPF` connection exceeds the `{argSet}` limit of 100 records.":["Requesting ",["amount"]," records on the `SPF` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting {amount} records on the `SSL` connection exceeds the `{argSet}` limit of 100 records.":["Requesting ",["amount"]," records on the `SSL` connection exceeds the `",["argSet"],"` limit of 100 records."],"Successfully added {domainCount} domain(s) to {0}.":["Successfully added ",["domainCount"]," domain(s) to ",["0"],"."],"Successfully added {domainCount} domains to {0}.":["Successfully added ",["domainCount"]," domains to ",["0"],"."],"Successfully archived organization: {0}.":["Successfully archived organization: ",["0"],"."],"Successfully closed account.":"Successfully closed account.","Successfully dispatched one time scan.":"Successfully dispatched one time scan.","Successfully dispatched subdomain discovery scan.":"Successfully dispatched subdomain discovery scan.","Successfully email verified account, and set TFA send method to email.":"Successfully email verified account, and set TFA send method to email.","Successfully invited user to organization, and sent notification email.":"Successfully invited user to organization, and sent notification email.","Successfully left organization: {0}":["Successfully left organization: ",["0"]],"Successfully removed domain: {0} from favourites.":["Successfully removed domain: ",["0"]," from favourites."],"Successfully removed domain: {0} from {1}.":["Successfully removed domain: ",["0"]," from ",["1"],"."],"Successfully removed organization: {0}.":["Successfully removed organization: ",["0"],"."],"Successfully removed user from organization.":"Successfully removed user from organization.","Successfully removed {domainCount} domain(s) from {0}.":["Successfully removed ",["domainCount"]," domain(s) from ",["0"],"."],"Successfully removed {domainCount} domains from {0}.":["Successfully removed ",["domainCount"]," domains from ",["0"],"."],"Successfully requested invite to organization, and sent notification email.":"Successfully requested invite to organization, and sent notification email.","Successfully sent invitation to service, and organization email.":"Successfully sent invitation to service, and organization email.","Successfully signed out.":"Successfully signed out.","Successfully transferred org: {0} ownership to user: {1}":["Successfully transferred org: ",["0"]," ownership to user: ",["1"]],"Successfully verified organization: {0}.":["Successfully verified organization: ",["0"],"."],"Successfully verified phone number, and set TFA send method to text.":"Successfully verified phone number, and set TFA send method to text.","Token value incorrect, please sign in again.":"Token value incorrect, please sign in again.","Too many failed login attempts, please reset your password, and try again.":"Too many failed login attempts, please reset your password, and try again.","Two factor code is incorrect. Please try again.":"Two factor code is incorrect. Please try again.","Two factor code length is incorrect. Please try again.":"Two factor code length is incorrect. Please try again.","Unable leave organization. Please try again.":"Unable leave organization. Please try again.","Unable to add domains in unknown organization.":"Unable to add domains in unknown organization.","Unable to archive organization. Please try again.":"Unable to archive organization. Please try again.","Unable to archive unknown organization.":"Unable to archive unknown organization.","Unable to authenticate. Please try again.":"Unable to authenticate. Please try again.","Unable to check permission. Please try again.":"Unable to check permission. Please try again.","Unable to close account of an undefined user.":"Unable to close account of an undefined user.","Unable to close account. Please try again.":"Unable to close account. Please try again.","Unable to create domain in unknown organization.":"Unable to create domain in unknown organization.","Unable to create domain, organization has already claimed it.":"Unable to create domain, organization has already claimed it.","Unable to create domain. Please try again.":"Unable to create domain. Please try again.","Unable to create domains. Please try again.":"Unable to create domains. Please try again.","Unable to create organization. Please try again.":"Unable to create organization. Please try again.","Unable to discover domains for unknown organization.":"Unable to discover domains for unknown organization.","Unable to dispatch one time scan. Please try again.":"Unable to dispatch one time scan. Please try again.","Unable to export organization. Please try again.":"Unable to export organization. Please try again.","Unable to favourite domain, user has already favourited it.":"Unable to favourite domain, user has already favourited it.","Unable to favourite domain. Please try again.":"Unable to favourite domain. Please try again.","Unable to favourite unknown domain.":"Unable to favourite unknown domain.","Unable to find Aggregate guidance tag(s). Please try again.":"Unable to find Aggregate guidance tag(s). Please try again.","Unable to find DKIM guidance tag(s). Please try again.":"Unable to find DKIM guidance tag(s). Please try again.","Unable to find DKIM result(s). Please try again.":"Unable to find DKIM result(s). Please try again.","Unable to find DKIM scan(s). Please try again.":"Unable to find DKIM scan(s). Please try again.","Unable to find DMARC guidance tag(s). Please try again.":"Unable to find DMARC guidance tag(s). Please try again.","Unable to find DMARC scan(s). Please try again.":"Unable to find DMARC scan(s). Please try again.","Unable to find DMARC summary data. Please try again.":"Unable to find DMARC summary data. Please try again.","Unable to find DNS scan(s). Please try again.":"Unable to find DNS scan(s). Please try again.","Unable to find HTTPS guidance tag(s). Please try again.":"Unable to find HTTPS guidance tag(s). Please try again.","Unable to find HTTPS scan(s). Please try again.":"Unable to find HTTPS scan(s). Please try again.","Unable to find SPF guidance tag(s). Please try again.":"Unable to find SPF guidance tag(s). Please try again.","Unable to find SPF scan(s). Please try again.":"Unable to find SPF scan(s). Please try again.","Unable to find SSL guidance tag(s). Please try again.":"Unable to find SSL guidance tag(s). Please try again.","Unable to find SSL scan(s). Please try again.":"Unable to find SSL scan(s). Please try again.","Unable to find the requested domain.":"Unable to find the requested domain.","Unable to find user affiliation(s). Please try again.":"Unable to find user affiliation(s). Please try again.","Unable to find verified organization(s). Please try again.":"Unable to find verified organization(s). Please try again.","Unable to invite user to organization. Please try again.":"Unable to invite user to organization. Please try again.","Unable to invite user to organization. User is already affiliated with organization.":"Unable to invite user to organization. User is already affiliated with organization.","Unable to invite user to unknown organization.":"Unable to invite user to unknown organization.","Unable to invite user. Please try again.":"Unable to invite user. Please try again.","Unable to invite yourself to an org.":"Unable to invite yourself to an org.","Unable to leave organization. Please try again.":"Unable to leave organization. Please try again.","Unable to leave undefined organization.":"Unable to leave undefined organization.","Unable to load Aggregate guidance tag(s). Please try again.":"Unable to load Aggregate guidance tag(s). Please try again.","Unable to load DKIM failure data. Please try again.":"Unable to load DKIM failure data. Please try again.","Unable to load DKIM guidance tag(s). Please try again.":"Unable to load DKIM guidance tag(s). Please try again.","Unable to load DKIM result(s). Please try again.":"Unable to load DKIM result(s). Please try again.","Unable to load DKIM scan(s). Please try again.":"Unable to load DKIM scan(s). Please try again.","Unable to load DKIM summary. Please try again.":"Unable to load DKIM summary. Please try again.","Unable to load DMARC failure data. Please try again.":"Unable to load DMARC failure data. Please try again.","Unable to load DMARC guidance tag(s). Please try again.":"Unable to load DMARC guidance tag(s). Please try again.","Unable to load DMARC phase summary. Please try again.":"Unable to load DMARC phase summary. Please try again.","Unable to load DMARC scan(s). Please try again.":"Unable to load DMARC scan(s). Please try again.","Unable to load DMARC summary data. Please try again.":"Unable to load DMARC summary data. Please try again.","Unable to load DMARC summary. Please try again.":"Unable to load DMARC summary. Please try again.","Unable to load DNS scan(s). Please try again.":"Unable to load DNS scan(s). Please try again.","Unable to load HTTPS guidance tag(s). Please try again.":"Unable to load HTTPS guidance tag(s). Please try again.","Unable to load HTTPS scan(s). Please try again.":"Unable to load HTTPS scan(s). Please try again.","Unable to load HTTPS summary. Please try again.":"Unable to load HTTPS summary. Please try again.","Unable to load SPF failure data. Please try again.":"Unable to load SPF failure data. Please try again.","Unable to load SPF guidance tag(s). Please try again.":"Unable to load SPF guidance tag(s). Please try again.","Unable to load SPF scan(s). Please try again.":"Unable to load SPF scan(s). Please try again.","Unable to load SPF summary. Please try again.":"Unable to load SPF summary. Please try again.","Unable to load SSL guidance tag(s). Please try again.":"Unable to load SSL guidance tag(s). Please try again.","Unable to load SSL scan(s). Please try again.":"Unable to load SSL scan(s). Please try again.","Unable to load SSL summary. Please try again.":"Unable to load SSL summary. Please try again.","Unable to load affiliation information. Please try again.":"Unable to load affiliation information. Please try again.","Unable to load affiliation(s). Please try again.":"Unable to load affiliation(s). Please try again.","Unable to load all organization domain statuses. Please try again.":"Unable to load all organization domain statuses. Please try again.","Unable to load domain(s). Please try again.":"Unable to load domain(s). Please try again.","Unable to load domain. Please try again.":"Unable to load domain. Please try again.","Unable to load full pass data. Please try again.":"Unable to load full pass data. Please try again.","Unable to load log(s). Please try again.":"Unable to load log(s). Please try again.","Unable to load log. Please try again.":"Unable to load log. Please try again.","Unable to load mail summary. Please try again.":"Unable to load mail summary. Please try again.","Unable to load organization domain statuses. Please try again.":"Unable to load organization domain statuses. Please try again.","Unable to load organization(s). Please try again.":"Unable to load organization(s). Please try again.","Unable to load owner information. Please try again.":"Unable to load owner information. Please try again.","Unable to load summary. Please try again.":"Unable to load summary. Please try again.","Unable to load tags(s). Please try again.":"Unable to load tags(s). Please try again.","Unable to load user(s). Please try again.":"Unable to load user(s). Please try again.","Unable to load verified domain(s). Please try again.":"Unable to load verified domain(s). Please try again.","Unable to load verified organization(s). Please try again.":"Unable to load verified organization(s). Please try again.","Unable to load web connections summary. Please try again.":"Unable to load web connections summary. Please try again.","Unable to load web scan(s). Please try again.":"Unable to load web scan(s). Please try again.","Unable to load web summary. Please try again.":"Unable to load web summary. Please try again.","Unable to query affiliation(s). Please try again.":"Unable to query affiliation(s). Please try again.","Unable to query domain(s). Please try again.":"Unable to query domain(s). Please try again.","Unable to query log(s). Please try again.":"Unable to query log(s). Please try again.","Unable to query user(s). Please try again.":"Unable to query user(s). Please try again.","Unable to refresh tokens, please sign in.":"Unable to refresh tokens, please sign in.","Unable to remove a user that already does not belong to this organization.":"Unable to remove a user that already does not belong to this organization.","Unable to remove domain from unknown organization.":"Unable to remove domain from unknown organization.","Unable to remove domain. Domain is not part of organization.":"Unable to remove domain. Domain is not part of organization.","Unable to remove domain. Please try again.":"Unable to remove domain. Please try again.","Unable to remove domains from unknown organization.":"Unable to remove domains from unknown organization.","Unable to remove organization. Please try again.":"Unable to remove organization. Please try again.","Unable to remove phone number. Please try again.":"Unable to remove phone number. Please try again.","Unable to remove unknown domain.":"Unable to remove unknown domain.","Unable to remove unknown organization.":"Unable to remove unknown organization.","Unable to remove unknown user from organization.":"Unable to remove unknown user from organization.","Unable to remove user from organization.":"Unable to remove user from organization.","Unable to remove user from this organization. Please try again.":"Unable to remove user from this organization. Please try again.","Unable to remove user from unknown organization.":"Unable to remove user from unknown organization.","Unable to request a one time scan on a domain that already has a pending scan.":"Unable to request a one time scan on a domain that already has a pending scan.","Unable to request a one time scan on an unknown domain.":"Unable to request a one time scan on an unknown domain.","Unable to request a one time scan. Please try again.":"Unable to request a one time scan. Please try again.","Unable to request a subdomain discovery scan on an invalid domain.":"Unable to request a subdomain discovery scan on an invalid domain.","Unable to request a subdomain discovery scan on an unknown domain.":"Unable to request a subdomain discovery scan on an unknown domain.","Unable to request invite to organization with which you are already affiliated.":"Unable to request invite to organization with which you are already affiliated.","Unable to request invite to organization with which you have already requested to join.":"Unable to request invite to organization with which you have already requested to join.","Unable to request invite to unknown organization.":"Unable to request invite to unknown organization.","Unable to request invite. Please try again.":"Unable to request invite. Please try again.","Unable to reset password. Please request a new email.":"Unable to reset password. Please request a new email.","Unable to reset password. Please try again.":"Unable to reset password. Please try again.","Unable to retrieve DMARC report information for: {domain}":["Unable to retrieve DMARC report information for: ",["domain"]],"Unable to select DMARC report(s) for this period and year.":"Unable to select DMARC report(s) for this period and year.","Unable to send authentication email. Please try again.":"Unable to send authentication email. Please try again.","Unable to send authentication text message. Please try again.":"Unable to send authentication text message. Please try again.","Unable to send org invite email. Please try again.":"Unable to send org invite email. Please try again.","Unable to send org invite request email. Please try again.":"Unable to send org invite request email. Please try again.","Unable to send password reset email. Please try again.":"Unable to send password reset email. Please try again.","Unable to send two factor authentication message. Please try again.":"Unable to send two factor authentication message. Please try again.","Unable to send verification email. Please try again.":"Unable to send verification email. Please try again.","Unable to set phone number, please try again.":"Unable to set phone number, please try again.","Unable to sign in, please try again.":"Unable to sign in, please try again.","Unable to sign up, please contact org admin for a new invite.":"Unable to sign up, please contact org admin for a new invite.","Unable to sign up. Please try again.":"Unable to sign up. Please try again.","Unable to transfer organization ownership. Please try again.":"Unable to transfer organization ownership. Please try again.","Unable to transfer ownership of a verified organization.":"Unable to transfer ownership of a verified organization.","Unable to transfer ownership of an org to an undefined user.":"Unable to transfer ownership of an org to an undefined user.","Unable to transfer ownership of undefined organization.":"Unable to transfer ownership of undefined organization.","Unable to transfer ownership to a user outside the org. Please invite the user and try again.":"Unable to transfer ownership to a user outside the org. Please invite the user and try again.","Unable to two factor authenticate. Please try again.":"Unable to two factor authenticate. Please try again.","Unable to unfavourite domain, domain is not favourited.":"Unable to unfavourite domain, domain is not favourited.","Unable to unfavourite domain. Please try again.":"Unable to unfavourite domain. Please try again.","Unable to unfavourite unknown domain.":"Unable to unfavourite unknown domain.","Unable to update domain edge. Please try again.":"Unable to update domain edge. Please try again.","Unable to update domain in an unknown org.":"Unable to update domain in an unknown org.","Unable to update domain that does not belong to the given organization.":"Unable to update domain that does not belong to the given organization.","Unable to update domain. Please try again.":"Unable to update domain. Please try again.","Unable to update organization. Please try again.":"Unable to update organization. Please try again.","Unable to update password, current password does not match. Please try again.":"Unable to update password, current password does not match. Please try again.","Unable to update password, new passwords do not match. Please try again.":"Unable to update password, new passwords do not match. Please try again.","Unable to update password, passwords do not match requirements. Please try again.":"Unable to update password, passwords do not match requirements. Please try again.","Unable to update password. Please try again.":"Unable to update password. Please try again.","Unable to update profile. Please try again.":"Unable to update profile. Please try again.","Unable to update role: organization unknown.":"Unable to update role: organization unknown.","Unable to update role: user does not belong to organization.":"Unable to update role: user does not belong to organization.","Unable to update role: user unknown.":"Unable to update role: user unknown.","Unable to update unknown domain.":"Unable to update unknown domain.","Unable to update unknown organization.":"Unable to update unknown organization.","Unable to update user's role. Please try again.":"Unable to update user's role. Please try again.","Unable to update your own role.":"Unable to update your own role.","Unable to verify account. Please request a new email.":"Unable to verify account. Please request a new email.","Unable to verify account. Please try again.":"Unable to verify account. Please try again.","Unable to verify if user is a super admin, please try again.":"Unable to verify if user is a super admin, please try again.","Unable to verify if user is an admin, please try again.":"Unable to verify if user is an admin, please try again.","Unable to verify organization. Please try again.":"Unable to verify organization. Please try again.","Unable to verify unknown organization.":"Unable to verify unknown organization.","User could not be queried.":"User could not be queried.","User role was updated successfully.":"User role was updated successfully.","Username not available, please try another.":"Username not available, please try another.","Verification error. Please activate multi-factor authentication to access content.":"Verification error. Please activate multi-factor authentication to access content.","Verification error. Please verify your account via email to access content.":"Verification error. Please verify your account via email to access content.","You must provide a `first` or `last` value to properly paginate the `Affiliation` connection.":"You must provide a `first` or `last` value to properly paginate the `Affiliation` connection.","You must provide a `first` or `last` value to properly paginate the `DKIMResults` connection.":"You must provide a `first` or `last` value to properly paginate the `DKIMResults` connection.","You must provide a `first` or `last` value to properly paginate the `DKIM` connection.":"You must provide a `first` or `last` value to properly paginate the `DKIM` connection.","You must provide a `first` or `last` value to properly paginate the `DMARC` connection.":"You must provide a `first` or `last` value to properly paginate the `DMARC` connection.","You must provide a `first` or `last` value to properly paginate the `DkimFailureTable` connection.":"You must provide a `first` or `last` value to properly paginate the `DkimFailureTable` connection.","You must provide a `first` or `last` value to properly paginate the `DmarcFailureTable` connection.":"You must provide a `first` or `last` value to properly paginate the `DmarcFailureTable` connection.","You must provide a `first` or `last` value to properly paginate the `DmarcSummaries` connection.":"You must provide a `first` or `last` value to properly paginate the `DmarcSummaries` connection.","You must provide a `first` or `last` value to properly paginate the `Domain` connection.":"You must provide a `first` or `last` value to properly paginate the `Domain` connection.","You must provide a `first` or `last` value to properly paginate the `FullPassTable` connection.":"You must provide a `first` or `last` value to properly paginate the `FullPassTable` connection.","You must provide a `first` or `last` value to properly paginate the `GuidanceTag` connection.":"You must provide a `first` or `last` value to properly paginate the `GuidanceTag` connection.","You must provide a `first` or `last` value to properly paginate the `HTTPS` connection.":"You must provide a `first` or `last` value to properly paginate the `HTTPS` connection.","You must provide a `first` or `last` value to properly paginate the `Log` connection.":"You must provide a `first` or `last` value to properly paginate the `Log` connection.","You must provide a `first` or `last` value to properly paginate the `Organization` connection.":"You must provide a `first` or `last` value to properly paginate the `Organization` connection.","You must provide a `first` or `last` value to properly paginate the `SPF` connection.":"You must provide a `first` or `last` value to properly paginate the `SPF` connection.","You must provide a `first` or `last` value to properly paginate the `SSL` connection.":"You must provide a `first` or `last` value to properly paginate the `SSL` connection.","You must provide a `first` or `last` value to properly paginate the `SpfFailureTable` connection.":"You must provide a `first` or `last` value to properly paginate the `SpfFailureTable` connection.","You must provide a `first` or `last` value to properly paginate the `User` connection.":"You must provide a `first` or `last` value to properly paginate the `User` connection.","You must provide a `first` or `last` value to properly paginate the `VerifiedDomain` connection.":"You must provide a `first` or `last` value to properly paginate the `VerifiedDomain` connection.","You must provide a `first` or `last` value to properly paginate the `VerifiedOrganization` connection.":"You must provide a `first` or `last` value to properly paginate the `VerifiedOrganization` connection.","You must provide a `limit` value in the range of 1-100 to properly paginate the `DNS` connection.":"You must provide a `limit` value in the range of 1-100 to properly paginate the `DNS` connection.","You must provide a `limit` value in the range of 1-100 to properly paginate the `MXRecord` connection.":"You must provide a `limit` value in the range of 1-100 to properly paginate the `MXRecord` connection.","You must provide a `limit` value in the range of 1-100 to properly paginate the `web` connection.":"You must provide a `limit` value in the range of 1-100 to properly paginate the `web` connection.","You must provide a `limit` value to properly paginate the `DNS` connection.":"You must provide a `limit` value to properly paginate the `DNS` connection.","You must provide a `limit` value to properly paginate the `MXRecord` connection.":"You must provide a `limit` value to properly paginate the `MXRecord` connection.","You must provide a `limit` value to properly paginate the `web` connection.":"You must provide a `limit` value to properly paginate the `web` connection.","You must provide a `period` value to access the `DmarcSummaries` connection.":"You must provide a `period` value to access the `DmarcSummaries` connection.","You must provide a `year` value to access the `DmarcSummaries` connection.":"You must provide a `year` value to access the `DmarcSummaries` connection.","You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `DNS` connection.":"You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `DNS` connection.","You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `MXRecord` connection.":"You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `MXRecord` connection.","You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `web` connection.":"You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `web` connection.","`{argSet}` must be of type `number` not `{typeSet}`.":["`",["argSet"],"` must be of type `number` not `",["typeSet"],"`."],"`{argSet}` on the `Affiliation` connection cannot be less than zero.":["`",["argSet"],"` on the `Affiliation` connection cannot be less than zero."],"`{argSet}` on the `DKIMResults` connection cannot be less than zero.":["`",["argSet"],"` on the `DKIMResults` connection cannot be less than zero."],"`{argSet}` on the `DKIM` connection cannot be less than zero.":["`",["argSet"],"` on the `DKIM` connection cannot be less than zero."],"`{argSet}` on the `DMARC` connection cannot be less than zero.":["`",["argSet"],"` on the `DMARC` connection cannot be less than zero."],"`{argSet}` on the `DkimFailureTable` connection cannot be less than zero.":["`",["argSet"],"` on the `DkimFailureTable` connection cannot be less than zero."],"`{argSet}` on the `DmarcFailureTable` connection cannot be less than zero.":["`",["argSet"],"` on the `DmarcFailureTable` connection cannot be less than zero."],"`{argSet}` on the `DmarcSummaries` connection cannot be less than zero.":["`",["argSet"],"` on the `DmarcSummaries` connection cannot be less than zero."],"`{argSet}` on the `Domain` connection cannot be less than zero.":["`",["argSet"],"` on the `Domain` connection cannot be less than zero."],"`{argSet}` on the `FullPassTable` connection cannot be less than zero.":["`",["argSet"],"` on the `FullPassTable` connection cannot be less than zero."],"`{argSet}` on the `GuidanceTag` connection cannot be less than zero.":["`",["argSet"],"` on the `GuidanceTag` connection cannot be less than zero."],"`{argSet}` on the `HTTPS` connection cannot be less than zero.":["`",["argSet"],"` on the `HTTPS` connection cannot be less than zero."],"`{argSet}` on the `Log` connection cannot be less than zero.":["`",["argSet"],"` on the `Log` connection cannot be less than zero."],"`{argSet}` on the `Organization` connection cannot be less than zero.":["`",["argSet"],"` on the `Organization` connection cannot be less than zero."],"`{argSet}` on the `SPF` connection cannot be less than zero.":["`",["argSet"],"` on the `SPF` connection cannot be less than zero."],"`{argSet}` on the `SSL` connection cannot be less than zero.":["`",["argSet"],"` on the `SSL` connection cannot be less than zero."],"`{argSet}` on the `SpfFailureTable` connection cannot be less than zero.":["`",["argSet"],"` on the `SpfFailureTable` connection cannot be less than zero."],"`{argSet}` on the `User` connection cannot be less than zero.":["`",["argSet"],"` on the `User` connection cannot be less than zero."],"`{argSet}` on the `VerifiedDomain` connection cannot be less than zero.":["`",["argSet"],"` on the `VerifiedDomain` connection cannot be less than zero."],"`{argSet}` on the `VerifiedOrganization` connection cannot be less than zero.":["`",["argSet"],"` on the `VerifiedOrganization` connection cannot be less than zero."]}}; \ No newline at end of file +/*eslint-disable*/module.exports={messages:{"Authentication error. Please sign in.":"Authentication error. Please sign in.","Cannot query additional findings without permission.":"Cannot query additional findings without permission.","Cannot query affiliations on organization without admin permission or higher.":"Cannot query affiliations on organization without admin permission or higher.","Cannot query audit logs on organization without admin permission or higher.":"Cannot query audit logs on organization without admin permission or higher.","Cannot query dns scan results without permission.":"Cannot query dns scan results without permission.","Cannot query domain selectors without permission.":"Cannot query domain selectors without permission.","Cannot query web scan results without permission.":"Cannot query web scan results without permission.","Email already in use.":"Email already in use.","Error while requesting scan. Please try again.":"Error while requesting scan. Please try again.","If an account with this username is found, a password reset link will be found in your inbox.":"If an account with this username is found, a password reset link will be found in your inbox.","If an account with this username is found, an email verification link will be found in your inbox.":"If an account with this username is found, an email verification link will be found in your inbox.","Incorrect TFA code. Please sign in again.":"Incorrect TFA code. Please sign in again.","Incorrect token value. Please request a new email.":"Incorrect token value. Please request a new email.","Incorrect username or password. Please try again.":"Incorrect username or password. Please try again.","Invalid token, please sign in.":"Invalid token, please sign in.","New passwords do not match.":"New passwords do not match.","No organization with the provided slug could be found.":"No organization with the provided slug could be found.","No verified domain with the provided domain could be found.":"No verified domain with the provided domain could be found.","No verified organization with the provided slug could be found.":"No verified organization with the provided slug could be found.","Organization has already been verified.":"Organization has already been verified.","Organization name already in use, please choose another and try again.":"Organization name already in use, please choose another and try again.","Organization name already in use. Please try again with a different name.":"Organization name already in use. Please try again with a different name.","Ownership check error. Unable to request domain information.":"Ownership check error. Unable to request domain information.","Passing both `first` and `last` to paginate the `Affiliation` connection is not supported.":"Passing both `first` and `last` to paginate the `Affiliation` connection is not supported.","Passing both `first` and `last` to paginate the `DKIMResults` connection is not supported.":"Passing both `first` and `last` to paginate the `DKIMResults` connection is not supported.","Passing both `first` and `last` to paginate the `DKIM` connection is not supported.":"Passing both `first` and `last` to paginate the `DKIM` connection is not supported.","Passing both `first` and `last` to paginate the `DMARC` connection is not supported.":"Passing both `first` and `last` to paginate the `DMARC` connection is not supported.","Passing both `first` and `last` to paginate the `DkimFailureTable` connection is not supported.":"Passing both `first` and `last` to paginate the `DkimFailureTable` connection is not supported.","Passing both `first` and `last` to paginate the `DmarcFailureTable` connection is not supported.":"Passing both `first` and `last` to paginate the `DmarcFailureTable` connection is not supported.","Passing both `first` and `last` to paginate the `DmarcSummaries` connection is not supported.":"Passing both `first` and `last` to paginate the `DmarcSummaries` connection is not supported.","Passing both `first` and `last` to paginate the `Domain` connection is not supported.":"Passing both `first` and `last` to paginate the `Domain` connection is not supported.","Passing both `first` and `last` to paginate the `FullPassTable` connection is not supported.":"Passing both `first` and `last` to paginate the `FullPassTable` connection is not supported.","Passing both `first` and `last` to paginate the `GuidanceTag` connection is not supported.":"Passing both `first` and `last` to paginate the `GuidanceTag` connection is not supported.","Passing both `first` and `last` to paginate the `HTTPS` connection is not supported.":"Passing both `first` and `last` to paginate the `HTTPS` connection is not supported.","Passing both `first` and `last` to paginate the `Log` connection is not supported.":"Passing both `first` and `last` to paginate the `Log` connection is not supported.","Passing both `first` and `last` to paginate the `Organization` connection is not supported.":"Passing both `first` and `last` to paginate the `Organization` connection is not supported.","Passing both `first` and `last` to paginate the `SPF` connection is not supported.":"Passing both `first` and `last` to paginate the `SPF` connection is not supported.","Passing both `first` and `last` to paginate the `SSL` connection is not supported.":"Passing both `first` and `last` to paginate the `SSL` connection is not supported.","Passing both `first` and `last` to paginate the `SpfFailureTable` connection is not supported.":"Passing both `first` and `last` to paginate the `SpfFailureTable` connection is not supported.","Passing both `first` and `last` to paginate the `User` connection is not supported.":"Passing both `first` and `last` to paginate the `User` connection is not supported.","Passing both `first` and `last` to paginate the `VerifiedDomain` connection is not supported.":"Passing both `first` and `last` to paginate the `VerifiedDomain` connection is not supported.","Passing both `first` and `last` to paginate the `VerifiedOrganization` connection is not supported.":"Passing both `first` and `last` to paginate the `VerifiedOrganization` connection is not supported.","Password does not meet requirements.":"Password does not meet requirements.","Password was successfully reset.":"Password was successfully reset.","Password was successfully updated.":"Password was successfully updated.","Passwords do not match.":"Passwords do not match.","Permission Denied: Could not retrieve specified organization.":"Permission Denied: Could not retrieve specified organization.","Permission Denied: Multi-factor authentication is required for admin accounts":"Permission Denied: Multi-factor authentication is required for admin accounts","Permission Denied: Please contact org owner to transfer ownership.":"Permission Denied: Please contact org owner to transfer ownership.","Permission Denied: Please contact organization admin for help with archiving domains.":"Permission Denied: Please contact organization admin for help with archiving domains.","Permission Denied: Please contact organization admin for help with removing domain.":"Permission Denied: Please contact organization admin for help with removing domain.","Permission Denied: Please contact organization admin for help with removing domains.":"Permission Denied: Please contact organization admin for help with removing domains.","Permission Denied: Please contact organization admin for help with removing organization.":"Permission Denied: Please contact organization admin for help with removing organization.","Permission Denied: Please contact organization admin for help with removing users.":"Permission Denied: Please contact organization admin for help with removing users.","Permission Denied: Please contact organization admin for help with updating organization.":"Permission Denied: Please contact organization admin for help with updating organization.","Permission Denied: Please contact organization admin for help with updating user roles.":"Permission Denied: Please contact organization admin for help with updating user roles.","Permission Denied: Please contact organization admin for help with user invitations.":"Permission Denied: Please contact organization admin for help with user invitations.","Permission Denied: Please contact organization admin for help with user role changes.":"Permission Denied: Please contact organization admin for help with user role changes.","Permission Denied: Please contact organization user for help with creating domain.":"Permission Denied: Please contact organization user for help with creating domain.","Permission Denied: Please contact organization user for help with creating domains.":"Permission Denied: Please contact organization user for help with creating domains.","Permission Denied: Please contact organization user for help with retrieving this domain.":"Permission Denied: Please contact organization user for help with retrieving this domain.","Permission Denied: Please contact organization user for help with scanning this domain.":"Permission Denied: Please contact organization user for help with scanning this domain.","Permission Denied: Please contact organization user for help with updating this domain.":"Permission Denied: Please contact organization user for help with updating this domain.","Permission Denied: Please contact super admin for help with archiving organization.":"Permission Denied: Please contact super admin for help with archiving organization.","Permission Denied: Please contact super admin for help with removing domain.":"Permission Denied: Please contact super admin for help with removing domain.","Permission Denied: Please contact super admin for help with removing organization.":"Permission Denied: Please contact super admin for help with removing organization.","Permission Denied: Please contact super admin for help with scanning this domain.":"Permission Denied: Please contact super admin for help with scanning this domain.","Permission Denied: Please contact super admin for help with verifying this organization.":"Permission Denied: Please contact super admin for help with verifying this organization.","Permission check error. Unable to request domain information.":"Permission check error. Unable to request domain information.","Permission error, not an admin for this user.":"Permission error, not an admin for this user.","Permission error: Unable to close other user's account.":"Permission error: Unable to close other user's account.","Permissions error. You do not have sufficient permissions to access this data.":"Permissions error. You do not have sufficient permissions to access this data.","Phone number has been successfully removed.":"Phone number has been successfully removed.","Phone number has been successfully set, you will receive a verification text message shortly.":"Phone number has been successfully set, you will receive a verification text message shortly.","Please provide a comment when adding an outside domain.":"Please provide a comment when adding an outside domain.","Profile successfully updated.":"Profile successfully updated.","Requesting `{amount}` records on the `Affiliation` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `Affiliation` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `DkimFailureTable` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `DkimFailureTable` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `DmarcFailureTable` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `DmarcFailureTable` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `DmarcSummaries` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `DmarcSummaries` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `Domain` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `Domain` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `FullPassTable` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `FullPassTable` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `GuidanceTag` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `GuidanceTag` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `Log` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `Log` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `Organization` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `Organization` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `SpfFailureTable` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `SpfFailureTable` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `User` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `User` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `VerifiedDomain` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `VerifiedDomain` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting `{amount}` records on the `VerifiedOrganization` connection exceeds the `{argSet}` limit of 100 records.":["Requesting `",["amount"],"` records on the `VerifiedOrganization` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting {amount} records on the `DKIMResults` connection exceeds the `{argSet}` limit of 100 records.":["Requesting ",["amount"]," records on the `DKIMResults` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting {amount} records on the `DKIM` connection exceeds the `{argSet}` limit of 100 records.":["Requesting ",["amount"]," records on the `DKIM` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting {amount} records on the `DMARC` connection exceeds the `{argSet}` limit of 100 records.":["Requesting ",["amount"]," records on the `DMARC` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting {amount} records on the `HTTPS` connection exceeds the `{argSet}` limit of 100 records.":["Requesting ",["amount"]," records on the `HTTPS` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting {amount} records on the `SPF` connection exceeds the `{argSet}` limit of 100 records.":["Requesting ",["amount"]," records on the `SPF` connection exceeds the `",["argSet"],"` limit of 100 records."],"Requesting {amount} records on the `SSL` connection exceeds the `{argSet}` limit of 100 records.":["Requesting ",["amount"]," records on the `SSL` connection exceeds the `",["argSet"],"` limit of 100 records."],"Successfully added {domainCount} domain(s) to {0}.":["Successfully added ",["domainCount"]," domain(s) to ",["0"],"."],"Successfully added {domainCount} domains to {0}.":["Successfully added ",["domainCount"]," domains to ",["0"],"."],"Successfully archived organization: {0}.":["Successfully archived organization: ",["0"],"."],"Successfully closed account.":"Successfully closed account.","Successfully dispatched one time scan.":"Successfully dispatched one time scan.","Successfully dispatched subdomain discovery scan.":"Successfully dispatched subdomain discovery scan.","Successfully email verified account, and set TFA send method to email.":"Successfully email verified account, and set TFA send method to email.","Successfully invited user to organization, and sent notification email.":"Successfully invited user to organization, and sent notification email.","Successfully left organization: {0}":["Successfully left organization: ",["0"]],"Successfully removed domain: {0} from favourites.":["Successfully removed domain: ",["0"]," from favourites."],"Successfully removed domain: {0} from {1}.":["Successfully removed domain: ",["0"]," from ",["1"],"."],"Successfully removed organization: {0}.":["Successfully removed organization: ",["0"],"."],"Successfully removed user from organization.":"Successfully removed user from organization.","Successfully removed {domainCount} domain(s) from {0}.":["Successfully removed ",["domainCount"]," domain(s) from ",["0"],"."],"Successfully removed {domainCount} domains from {0}.":["Successfully removed ",["domainCount"]," domains from ",["0"],"."],"Successfully requested invite to organization, and sent notification email.":"Successfully requested invite to organization, and sent notification email.","Successfully sent invitation to service, and organization email.":"Successfully sent invitation to service, and organization email.","Successfully signed out.":"Successfully signed out.","Successfully transferred org: {0} ownership to user: {1}":["Successfully transferred org: ",["0"]," ownership to user: ",["1"]],"Successfully verified organization: {0}.":["Successfully verified organization: ",["0"],"."],"Successfully verified phone number, and set TFA send method to text.":"Successfully verified phone number, and set TFA send method to text.","Token value incorrect, please sign in again.":"Token value incorrect, please sign in again.","Too many failed login attempts, please reset your password, and try again.":"Too many failed login attempts, please reset your password, and try again.","Two factor code is incorrect. Please try again.":"Two factor code is incorrect. Please try again.","Two factor code length is incorrect. Please try again.":"Two factor code length is incorrect. Please try again.","Unable leave organization. Please try again.":"Unable leave organization. Please try again.","Unable to add domains in unknown organization.":"Unable to add domains in unknown organization.","Unable to archive organization. Please try again.":"Unable to archive organization. Please try again.","Unable to archive unknown organization.":"Unable to archive unknown organization.","Unable to authenticate. Please try again.":"Unable to authenticate. Please try again.","Unable to check permission. Please try again.":"Unable to check permission. Please try again.","Unable to close account of an undefined user.":"Unable to close account of an undefined user.","Unable to close account. Please try again.":"Unable to close account. Please try again.","Unable to create domain in unknown organization.":"Unable to create domain in unknown organization.","Unable to create domain, organization has already claimed it.":"Unable to create domain, organization has already claimed it.","Unable to create domain. Please try again.":"Unable to create domain. Please try again.","Unable to create domains. Please try again.":"Unable to create domains. Please try again.","Unable to create organization. Please try again.":"Unable to create organization. Please try again.","Unable to discover domains for unknown organization.":"Unable to discover domains for unknown organization.","Unable to dispatch one time scan. Please try again.":"Unable to dispatch one time scan. Please try again.","Unable to export organization. Please try again.":"Unable to export organization. Please try again.","Unable to favourite domain, user has already favourited it.":"Unable to favourite domain, user has already favourited it.","Unable to favourite domain. Please try again.":"Unable to favourite domain. Please try again.","Unable to favourite unknown domain.":"Unable to favourite unknown domain.","Unable to find Aggregate guidance tag(s). Please try again.":"Unable to find Aggregate guidance tag(s). Please try again.","Unable to find DKIM guidance tag(s). Please try again.":"Unable to find DKIM guidance tag(s). Please try again.","Unable to find DKIM result(s). Please try again.":"Unable to find DKIM result(s). Please try again.","Unable to find DKIM scan(s). Please try again.":"Unable to find DKIM scan(s). Please try again.","Unable to find DMARC guidance tag(s). Please try again.":"Unable to find DMARC guidance tag(s). Please try again.","Unable to find DMARC scan(s). Please try again.":"Unable to find DMARC scan(s). Please try again.","Unable to find DMARC summary data. Please try again.":"Unable to find DMARC summary data. Please try again.","Unable to find DNS scan(s). Please try again.":"Unable to find DNS scan(s). Please try again.","Unable to find HTTPS guidance tag(s). Please try again.":"Unable to find HTTPS guidance tag(s). Please try again.","Unable to find HTTPS scan(s). Please try again.":"Unable to find HTTPS scan(s). Please try again.","Unable to find SPF guidance tag(s). Please try again.":"Unable to find SPF guidance tag(s). Please try again.","Unable to find SPF scan(s). Please try again.":"Unable to find SPF scan(s). Please try again.","Unable to find SSL guidance tag(s). Please try again.":"Unable to find SSL guidance tag(s). Please try again.","Unable to find SSL scan(s). Please try again.":"Unable to find SSL scan(s). Please try again.","Unable to find the requested domain.":"Unable to find the requested domain.","Unable to find user affiliation(s). Please try again.":"Unable to find user affiliation(s). Please try again.","Unable to find verified organization(s). Please try again.":"Unable to find verified organization(s). Please try again.","Unable to invite user to organization. Please try again.":"Unable to invite user to organization. Please try again.","Unable to invite user to organization. User is already affiliated with organization.":"Unable to invite user to organization. User is already affiliated with organization.","Unable to invite user to unknown organization.":"Unable to invite user to unknown organization.","Unable to invite user. Please try again.":"Unable to invite user. Please try again.","Unable to invite yourself to an org.":"Unable to invite yourself to an org.","Unable to leave organization. Please try again.":"Unable to leave organization. Please try again.","Unable to leave undefined organization.":"Unable to leave undefined organization.","Unable to load Aggregate guidance tag(s). Please try again.":"Unable to load Aggregate guidance tag(s). Please try again.","Unable to load DKIM failure data. Please try again.":"Unable to load DKIM failure data. Please try again.","Unable to load DKIM guidance tag(s). Please try again.":"Unable to load DKIM guidance tag(s). Please try again.","Unable to load DKIM result(s). Please try again.":"Unable to load DKIM result(s). Please try again.","Unable to load DKIM scan(s). Please try again.":"Unable to load DKIM scan(s). Please try again.","Unable to load DKIM summary. Please try again.":"Unable to load DKIM summary. Please try again.","Unable to load DMARC failure data. Please try again.":"Unable to load DMARC failure data. Please try again.","Unable to load DMARC guidance tag(s). Please try again.":"Unable to load DMARC guidance tag(s). Please try again.","Unable to load DMARC phase summary. Please try again.":"Unable to load DMARC phase summary. Please try again.","Unable to load DMARC scan(s). Please try again.":"Unable to load DMARC scan(s). Please try again.","Unable to load DMARC summary data. Please try again.":"Unable to load DMARC summary data. Please try again.","Unable to load DMARC summary. Please try again.":"Unable to load DMARC summary. Please try again.","Unable to load DNS scan(s). Please try again.":"Unable to load DNS scan(s). Please try again.","Unable to load HTTPS guidance tag(s). Please try again.":"Unable to load HTTPS guidance tag(s). Please try again.","Unable to load HTTPS scan(s). Please try again.":"Unable to load HTTPS scan(s). Please try again.","Unable to load HTTPS summary. Please try again.":"Unable to load HTTPS summary. Please try again.","Unable to load SPF failure data. Please try again.":"Unable to load SPF failure data. Please try again.","Unable to load SPF guidance tag(s). Please try again.":"Unable to load SPF guidance tag(s). Please try again.","Unable to load SPF scan(s). Please try again.":"Unable to load SPF scan(s). Please try again.","Unable to load SPF summary. Please try again.":"Unable to load SPF summary. Please try again.","Unable to load SSL guidance tag(s). Please try again.":"Unable to load SSL guidance tag(s). Please try again.","Unable to load SSL scan(s). Please try again.":"Unable to load SSL scan(s). Please try again.","Unable to load SSL summary. Please try again.":"Unable to load SSL summary. Please try again.","Unable to load additional findings. Please try again.":"Unable to load additional findings. Please try again.","Unable to load affiliation information. Please try again.":"Unable to load affiliation information. Please try again.","Unable to load affiliation(s). Please try again.":"Unable to load affiliation(s). Please try again.","Unable to load all organization domain statuses. Please try again.":"Unable to load all organization domain statuses. Please try again.","Unable to load chart summary data. Please try again.":"Unable to load chart summary data. Please try again.","Unable to load domain selector(s). Please try again.":"Unable to load domain selector(s). Please try again.","Unable to load domain(s). Please try again.":"Unable to load domain(s). Please try again.","Unable to load domain. Please try again.":"Unable to load domain. Please try again.","Unable to load full pass data. Please try again.":"Unable to load full pass data. Please try again.","Unable to load log(s). Please try again.":"Unable to load log(s). Please try again.","Unable to load log. Please try again.":"Unable to load log. Please try again.","Unable to load mail summary. Please try again.":"Unable to load mail summary. Please try again.","Unable to load organization domain statuses. Please try again.":"Unable to load organization domain statuses. Please try again.","Unable to load organization summary data. Please try again.":"Unable to load organization summary data. Please try again.","Unable to load organization(s). Please try again.":"Unable to load organization(s). Please try again.","Unable to load owner information. Please try again.":"Unable to load owner information. Please try again.","Unable to load summary. Please try again.":"Unable to load summary. Please try again.","Unable to load tags(s). Please try again.":"Unable to load tags(s). Please try again.","Unable to load user(s). Please try again.":"Unable to load user(s). Please try again.","Unable to load verified domain(s). Please try again.":"Unable to load verified domain(s). Please try again.","Unable to load verified organization(s). Please try again.":"Unable to load verified organization(s). Please try again.","Unable to load verified rua domains. Please try again.":"Unable to load verified rua domains. Please try again.","Unable to load web connections summary. Please try again.":"Unable to load web connections summary. Please try again.","Unable to load web scan(s). Please try again.":"Unable to load web scan(s). Please try again.","Unable to load web summary. Please try again.":"Unable to load web summary. Please try again.","Unable to query affiliation(s). Please try again.":"Unable to query affiliation(s). Please try again.","Unable to query domain(s). Please try again.":"Unable to query domain(s). Please try again.","Unable to query log(s). Please try again.":"Unable to query log(s). Please try again.","Unable to query user(s). Please try again.":"Unable to query user(s). Please try again.","Unable to refresh tokens, please sign in.":"Unable to refresh tokens, please sign in.","Unable to remove a user that already does not belong to this organization.":"Unable to remove a user that already does not belong to this organization.","Unable to remove domain from unknown organization.":"Unable to remove domain from unknown organization.","Unable to remove domain. Domain is not part of organization.":"Unable to remove domain. Domain is not part of organization.","Unable to remove domain. Please try again.":"Unable to remove domain. Please try again.","Unable to remove domains from unknown organization.":"Unable to remove domains from unknown organization.","Unable to remove organization. Please try again.":"Unable to remove organization. Please try again.","Unable to remove phone number. Please try again.":"Unable to remove phone number. Please try again.","Unable to remove unknown domain.":"Unable to remove unknown domain.","Unable to remove unknown organization.":"Unable to remove unknown organization.","Unable to remove unknown user from organization.":"Unable to remove unknown user from organization.","Unable to remove user from organization.":"Unable to remove user from organization.","Unable to remove user from this organization. Please try again.":"Unable to remove user from this organization. Please try again.","Unable to remove user from unknown organization.":"Unable to remove user from unknown organization.","Unable to request a one time scan on a domain that already has a pending scan.":"Unable to request a one time scan on a domain that already has a pending scan.","Unable to request a one time scan on an unknown domain.":"Unable to request a one time scan on an unknown domain.","Unable to request a one time scan. Please try again.":"Unable to request a one time scan. Please try again.","Unable to request a subdomain discovery scan on an invalid domain.":"Unable to request a subdomain discovery scan on an invalid domain.","Unable to request a subdomain discovery scan on an unknown domain.":"Unable to request a subdomain discovery scan on an unknown domain.","Unable to request invite to organization with which you are already affiliated.":"Unable to request invite to organization with which you are already affiliated.","Unable to request invite to organization with which you have already requested to join.":"Unable to request invite to organization with which you have already requested to join.","Unable to request invite to unknown organization.":"Unable to request invite to unknown organization.","Unable to request invite. Please try again.":"Unable to request invite. Please try again.","Unable to reset password. Please request a new email.":"Unable to reset password. Please request a new email.","Unable to reset password. Please try again.":"Unable to reset password. Please try again.","Unable to retrieve DMARC report information for: {domain}":["Unable to retrieve DMARC report information for: ",["domain"]],"Unable to select DMARC report(s) for this period and year.":"Unable to select DMARC report(s) for this period and year.","Unable to send authentication email. Please try again.":"Unable to send authentication email. Please try again.","Unable to send authentication text message. Please try again.":"Unable to send authentication text message. Please try again.","Unable to send org invite email. Please try again.":"Unable to send org invite email. Please try again.","Unable to send org invite request email. Please try again.":"Unable to send org invite request email. Please try again.","Unable to send password reset email. Please try again.":"Unable to send password reset email. Please try again.","Unable to send two factor authentication message. Please try again.":"Unable to send two factor authentication message. Please try again.","Unable to send verification email. Please try again.":"Unable to send verification email. Please try again.","Unable to set phone number, please try again.":"Unable to set phone number, please try again.","Unable to sign in, please try again.":"Unable to sign in, please try again.","Unable to sign up, please contact org admin for a new invite.":"Unable to sign up, please contact org admin for a new invite.","Unable to sign up. Please try again.":"Unable to sign up. Please try again.","Unable to transfer organization ownership. Please try again.":"Unable to transfer organization ownership. Please try again.","Unable to transfer ownership of a verified organization.":"Unable to transfer ownership of a verified organization.","Unable to transfer ownership of an org to an undefined user.":"Unable to transfer ownership of an org to an undefined user.","Unable to transfer ownership of undefined organization.":"Unable to transfer ownership of undefined organization.","Unable to transfer ownership to a user outside the org. Please invite the user and try again.":"Unable to transfer ownership to a user outside the org. Please invite the user and try again.","Unable to two factor authenticate. Please try again.":"Unable to two factor authenticate. Please try again.","Unable to unfavourite domain, domain is not favourited.":"Unable to unfavourite domain, domain is not favourited.","Unable to unfavourite domain. Please try again.":"Unable to unfavourite domain. Please try again.","Unable to unfavourite unknown domain.":"Unable to unfavourite unknown domain.","Unable to update domain edge. Please try again.":"Unable to update domain edge. Please try again.","Unable to update domain in an unknown org.":"Unable to update domain in an unknown org.","Unable to update domain that does not belong to the given organization.":"Unable to update domain that does not belong to the given organization.","Unable to update domain. Please try again.":"Unable to update domain. Please try again.","Unable to update organization. Please try again.":"Unable to update organization. Please try again.","Unable to update password, current password does not match. Please try again.":"Unable to update password, current password does not match. Please try again.","Unable to update password, new passwords do not match. Please try again.":"Unable to update password, new passwords do not match. Please try again.","Unable to update password, passwords do not match requirements. Please try again.":"Unable to update password, passwords do not match requirements. Please try again.","Unable to update password. Please try again.":"Unable to update password. Please try again.","Unable to update profile. Please try again.":"Unable to update profile. Please try again.","Unable to update role: organization unknown.":"Unable to update role: organization unknown.","Unable to update role: user does not belong to organization.":"Unable to update role: user does not belong to organization.","Unable to update role: user unknown.":"Unable to update role: user unknown.","Unable to update unknown domain.":"Unable to update unknown domain.","Unable to update unknown organization.":"Unable to update unknown organization.","Unable to update user's role. Please try again.":"Unable to update user's role. Please try again.","Unable to update your own role.":"Unable to update your own role.","Unable to verify account. Please request a new email.":"Unable to verify account. Please request a new email.","Unable to verify account. Please try again.":"Unable to verify account. Please try again.","Unable to verify if user is a super admin, please try again.":"Unable to verify if user is a super admin, please try again.","Unable to verify if user is an admin, please try again.":"Unable to verify if user is an admin, please try again.","Unable to verify organization. Please try again.":"Unable to verify organization. Please try again.","Unable to verify unknown organization.":"Unable to verify unknown organization.","User could not be queried.":"User could not be queried.","User role was updated successfully.":"User role was updated successfully.","Username not available, please try another.":"Username not available, please try another.","Verification error. Please activate multi-factor authentication to access content.":"Verification error. Please activate multi-factor authentication to access content.","Verification error. Please verify your account via email to access content.":"Verification error. Please verify your account via email to access content.","You must provide a `domainId` to retrieve a domain's additional findings.":"You must provide a `domainId` to retrieve a domain's additional findings.","You must provide a `first` or `last` value to properly paginate the `Affiliation` connection.":"You must provide a `first` or `last` value to properly paginate the `Affiliation` connection.","You must provide a `first` or `last` value to properly paginate the `DKIMResults` connection.":"You must provide a `first` or `last` value to properly paginate the `DKIMResults` connection.","You must provide a `first` or `last` value to properly paginate the `DKIM` connection.":"You must provide a `first` or `last` value to properly paginate the `DKIM` connection.","You must provide a `first` or `last` value to properly paginate the `DMARC` connection.":"You must provide a `first` or `last` value to properly paginate the `DMARC` connection.","You must provide a `first` or `last` value to properly paginate the `DkimFailureTable` connection.":"You must provide a `first` or `last` value to properly paginate the `DkimFailureTable` connection.","You must provide a `first` or `last` value to properly paginate the `DmarcFailureTable` connection.":"You must provide a `first` or `last` value to properly paginate the `DmarcFailureTable` connection.","You must provide a `first` or `last` value to properly paginate the `DmarcSummaries` connection.":"You must provide a `first` or `last` value to properly paginate the `DmarcSummaries` connection.","You must provide a `first` or `last` value to properly paginate the `Domain` connection.":"You must provide a `first` or `last` value to properly paginate the `Domain` connection.","You must provide a `first` or `last` value to properly paginate the `FullPassTable` connection.":"You must provide a `first` or `last` value to properly paginate the `FullPassTable` connection.","You must provide a `first` or `last` value to properly paginate the `GuidanceTag` connection.":"You must provide a `first` or `last` value to properly paginate the `GuidanceTag` connection.","You must provide a `first` or `last` value to properly paginate the `HTTPS` connection.":"You must provide a `first` or `last` value to properly paginate the `HTTPS` connection.","You must provide a `first` or `last` value to properly paginate the `Log` connection.":"You must provide a `first` or `last` value to properly paginate the `Log` connection.","You must provide a `first` or `last` value to properly paginate the `Organization` connection.":"You must provide a `first` or `last` value to properly paginate the `Organization` connection.","You must provide a `first` or `last` value to properly paginate the `SPF` connection.":"You must provide a `first` or `last` value to properly paginate the `SPF` connection.","You must provide a `first` or `last` value to properly paginate the `SSL` connection.":"You must provide a `first` or `last` value to properly paginate the `SSL` connection.","You must provide a `first` or `last` value to properly paginate the `SpfFailureTable` connection.":"You must provide a `first` or `last` value to properly paginate the `SpfFailureTable` connection.","You must provide a `first` or `last` value to properly paginate the `User` connection.":"You must provide a `first` or `last` value to properly paginate the `User` connection.","You must provide a `first` or `last` value to properly paginate the `VerifiedDomain` connection.":"You must provide a `first` or `last` value to properly paginate the `VerifiedDomain` connection.","You must provide a `first` or `last` value to properly paginate the `VerifiedOrganization` connection.":"You must provide a `first` or `last` value to properly paginate the `VerifiedOrganization` connection.","You must provide a `limit` value in the range of 1-100 to properly paginate the `DNS` connection.":"You must provide a `limit` value in the range of 1-100 to properly paginate the `DNS` connection.","You must provide a `limit` value in the range of 1-100 to properly paginate the `MXRecord` connection.":"You must provide a `limit` value in the range of 1-100 to properly paginate the `MXRecord` connection.","You must provide a `limit` value in the range of 1-100 to properly paginate the `web` connection.":"You must provide a `limit` value in the range of 1-100 to properly paginate the `web` connection.","You must provide a `limit` value to properly paginate the `DNS` connection.":"You must provide a `limit` value to properly paginate the `DNS` connection.","You must provide a `limit` value to properly paginate the `MXRecord` connection.":"You must provide a `limit` value to properly paginate the `MXRecord` connection.","You must provide a `limit` value to properly paginate the `web` connection.":"You must provide a `limit` value to properly paginate the `web` connection.","You must provide a `period` value to access the `ChartSummaries` connection.":"You must provide a `period` value to access the `ChartSummaries` connection.","You must provide a `period` value to access the `DmarcSummaries` connection.":"You must provide a `period` value to access the `DmarcSummaries` connection.","You must provide a `period` value to access the `OrganizationSummaries` connection.":"You must provide a `period` value to access the `OrganizationSummaries` connection.","You must provide a `year` value to access the `ChartSummaries` connection.":"You must provide a `year` value to access the `ChartSummaries` connection.","You must provide a `year` value to access the `DmarcSummaries` connection.":"You must provide a `year` value to access the `DmarcSummaries` connection.","You must provide a `year` value to access the `OrganizationSummaries` connection.":"You must provide a `year` value to access the `OrganizationSummaries` connection.","You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `DNS` connection.":"You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `DNS` connection.","You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `MXRecord` connection.":"You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `MXRecord` connection.","You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `web` connection.":"You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `web` connection.","`{argSet}` must be of type `number` not `{typeSet}`.":["`",["argSet"],"` must be of type `number` not `",["typeSet"],"`."],"`{argSet}` on the `Affiliation` connection cannot be less than zero.":["`",["argSet"],"` on the `Affiliation` connection cannot be less than zero."],"`{argSet}` on the `DKIMResults` connection cannot be less than zero.":["`",["argSet"],"` on the `DKIMResults` connection cannot be less than zero."],"`{argSet}` on the `DKIM` connection cannot be less than zero.":["`",["argSet"],"` on the `DKIM` connection cannot be less than zero."],"`{argSet}` on the `DMARC` connection cannot be less than zero.":["`",["argSet"],"` on the `DMARC` connection cannot be less than zero."],"`{argSet}` on the `DkimFailureTable` connection cannot be less than zero.":["`",["argSet"],"` on the `DkimFailureTable` connection cannot be less than zero."],"`{argSet}` on the `DmarcFailureTable` connection cannot be less than zero.":["`",["argSet"],"` on the `DmarcFailureTable` connection cannot be less than zero."],"`{argSet}` on the `DmarcSummaries` connection cannot be less than zero.":["`",["argSet"],"` on the `DmarcSummaries` connection cannot be less than zero."],"`{argSet}` on the `Domain` connection cannot be less than zero.":["`",["argSet"],"` on the `Domain` connection cannot be less than zero."],"`{argSet}` on the `FullPassTable` connection cannot be less than zero.":["`",["argSet"],"` on the `FullPassTable` connection cannot be less than zero."],"`{argSet}` on the `GuidanceTag` connection cannot be less than zero.":["`",["argSet"],"` on the `GuidanceTag` connection cannot be less than zero."],"`{argSet}` on the `HTTPS` connection cannot be less than zero.":["`",["argSet"],"` on the `HTTPS` connection cannot be less than zero."],"`{argSet}` on the `Log` connection cannot be less than zero.":["`",["argSet"],"` on the `Log` connection cannot be less than zero."],"`{argSet}` on the `Organization` connection cannot be less than zero.":["`",["argSet"],"` on the `Organization` connection cannot be less than zero."],"`{argSet}` on the `SPF` connection cannot be less than zero.":["`",["argSet"],"` on the `SPF` connection cannot be less than zero."],"`{argSet}` on the `SSL` connection cannot be less than zero.":["`",["argSet"],"` on the `SSL` connection cannot be less than zero."],"`{argSet}` on the `SpfFailureTable` connection cannot be less than zero.":["`",["argSet"],"` on the `SpfFailureTable` connection cannot be less than zero."],"`{argSet}` on the `User` connection cannot be less than zero.":["`",["argSet"],"` on the `User` connection cannot be less than zero."],"`{argSet}` on the `VerifiedDomain` connection cannot be less than zero.":["`",["argSet"],"` on the `VerifiedDomain` connection cannot be less than zero."],"`{argSet}` on the `VerifiedOrganization` connection cannot be less than zero.":["`",["argSet"],"` on the `VerifiedOrganization` connection cannot be less than zero."]}}; \ No newline at end of file diff --git a/api/src/locale/fr/messages.js b/api/src/locale/fr/messages.js index 940486f566..2aa919020f 100644 --- a/api/src/locale/fr/messages.js +++ b/api/src/locale/fr/messages.js @@ -1 +1 @@ -/*eslint-disable*/module.exports={messages:{"Authentication error. Please sign in.":"Erreur d'authentification. Veuillez vous connecter.","Cannot query affiliations on organization without admin permission or higher.":"Impossible d'interroger les affiliations sur l'organisation sans l'autorisation de l'administrateur ou plus.","Cannot query audit logs on organization without admin permission or higher.":"Impossible d'interroger les journaux d'audit sur l'organisation sans l'autorisation d'administrateur ou plus.","Cannot query dns scan results without permission.":"Impossible d'interroger les résultats de l'analyse DNS sans autorisation.","Cannot query domain selectors without permission.":"Impossible d'interroger les sélecteurs de domaine sans autorisation.","Cannot query web scan results without permission.":"Impossible d'interroger les résultats de l'analyse web sans autorisation.","Email already in use.":"Courriel déjà utilisé.","Error while requesting scan. Please try again.":"Erreur lors de la demande d'analyse. Veuillez réessayer.","If an account with this username is found, a password reset link will be found in your inbox.":"Si un compte avec ce nom d'utilisateur est trouvé, un lien de réinitialisation du mot de passe se trouvera dans votre boîte de réception.","If an account with this username is found, an email verification link will be found in your inbox.":"Si un compte avec ce nom d'utilisateur est trouvé, un lien de vérification par e-mail sera trouvé dans votre boîte de réception.","Incorrect TFA code. Please sign in again.":"Code TFA incorrect. Veuillez vous reconnecter.","Incorrect token value. Please request a new email.":"La valeur du jeton est incorrecte. Veuillez demander un nouvel e-mail.","Incorrect username or password. Please try again.":"Le nom d'utilisateur ou le mot de passe est incorrect. Veuillez réessayer.","Invalid token, please sign in.":"Jeton invalide, veuillez vous connecter.","New passwords do not match.":"Les nouveaux mots de passe ne correspondent pas.","No organization with the provided slug could be found.":"Aucune organisation avec le slug fourni n'a pu être trouvée.","No verified domain with the provided domain could be found.":"Aucun domaine vérifié avec le domaine fourni n'a pu être trouvé.","No verified organization with the provided slug could be found.":"Aucune organisation vérifiée avec le slug fourni n'a pu être trouvée.","Organization has already been verified.":"L'organisation a déjà été vérifiée.","Organization name already in use, please choose another and try again.":"Le nom de l'organisation est déjà utilisé, veuillez en choisir un autre et réessayer.","Organization name already in use. Please try again with a different name.":"Le nom de l'organisation est déjà utilisé. Veuillez réessayer avec un nom différent.","Ownership check error. Unable to request domain information.":"Erreur de vérification de la propriété. Impossible de demander des informations sur le domaine.","Passing both `first` and `last` to paginate the `Affiliation` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `Affiliation` n'est pas supporté.","Passing both `first` and `last` to paginate the `DKIMResults` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `DKIMResults` n'est pas supporté.","Passing both `first` and `last` to paginate the `DKIM` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `DKIMResults` n'est pas supporté.","Passing both `first` and `last` to paginate the `DMARC` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `DMARC` n'est pas supporté.","Passing both `first` and `last` to paginate the `DkimFailureTable` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `DkimFailureTable` n'est pas supporté.","Passing both `first` and `last` to paginate the `DmarcFailureTable` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `DmarcFailureTable` n'est pas supporté.","Passing both `first` and `last` to paginate the `DmarcSummaries` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `DmarcSummaries` n'est pas supporté.","Passing both `first` and `last` to paginate the `Domain` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `Domain` n'est pas supporté.","Passing both `first` and `last` to paginate the `FullPassTable` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `FullPassTable` n'est pas supporté.","Passing both `first` and `last` to paginate the `GuidanceTag` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `GuidanceTag` n'est pas supporté.","Passing both `first` and `last` to paginate the `HTTPS` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `HTTPS` n'est pas supporté.","Passing both `first` and `last` to paginate the `Log` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `Log` n'est pas supporté.","Passing both `first` and `last` to paginate the `Organization` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `Organization` n'est pas supporté.","Passing both `first` and `last` to paginate the `SPF` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `SPF` n'est pas supporté.","Passing both `first` and `last` to paginate the `SSL` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `SSL` n'est pas supporté.","Passing both `first` and `last` to paginate the `SpfFailureTable` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `SpfFailureTable` n'est pas supporté.","Passing both `first` and `last` to paginate the `User` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `User` n'est pas supporté.","Passing both `first` and `last` to paginate the `VerifiedDomain` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `VerifiedDomain` n'est pas supporté.","Passing both `first` and `last` to paginate the `VerifiedOrganization` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `VerifiedOrganization` n'est pas supporté.","Password does not meet requirements.":"Le mot de passe ne répond pas aux exigences.","Password was successfully reset.":"Le mot de passe a été réinitialisé avec succès.","Password was successfully updated.":"Le mot de passe a été mis à jour avec succès.","Passwords do not match.":"Les mots de passe ne correspondent pas.","Permission Denied: Could not retrieve specified organization.":"Permission refusée : Impossible de récupérer l'organisation spécifiée.","Permission Denied: Multi-factor authentication is required for admin accounts":"Permission refusée : L'authentification multifactorielle est requise pour les comptes admin.","Permission Denied: Please contact org owner to transfer ownership.":"Permission refusée : Veuillez contacter le propriétaire de l'org pour transférer la propriété.","Permission Denied: Please contact organization admin for help with archiving domains.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide sur l'archivage des domaines.","Permission Denied: Please contact organization admin for help with removing domain.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide afin de supprimer le domaine.","Permission Denied: Please contact organization admin for help with removing domains.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide sur la suppression des domaines.","Permission Denied: Please contact organization admin for help with removing organization.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide afin de supprimer l'organisation.","Permission Denied: Please contact organization admin for help with removing users.":"Autorisation refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide sur la suppression des utilisateurs.","Permission Denied: Please contact organization admin for help with updating organization.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide sur la suppression des utilisateurs.","Permission Denied: Please contact organization admin for help with updating user roles.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide sur la mise à jour des rôles des utilisateurs.","Permission Denied: Please contact organization admin for help with user invitations.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide concernant les invitations d'utilisateurs.","Permission Denied: Please contact organization admin for help with user role changes.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide sur les changements de rôle des utilisateurs.","Permission Denied: Please contact organization user for help with creating domain.":"Permission refusée : Veuillez contacter l'utilisateur de l'organisation pour obtenir de l'aide sur la création du domaine.","Permission Denied: Please contact organization user for help with creating domains.":"Permission refusée : Veuillez contacter l'utilisateur de l'organisation pour obtenir de l'aide sur la création de domaines.","Permission Denied: Please contact organization user for help with retrieving this domain.":"Permission refusée : Veuillez contacter l'utilisateur de l'organisation pour obtenir de l'aide pour récupérer ce domaine.","Permission Denied: Please contact organization user for help with scanning this domain.":"Permission refusée : Veuillez contacter l'utilisateur de l'organisation pour obtenir de l'aide sur l'analyse de ce domaine.","Permission Denied: Please contact organization user for help with updating this domain.":"Autorisation refusée : Veuillez contacter l'utilisateur de l'organisation pour obtenir de l'aide sur la mise à jour de ce domaine.","Permission Denied: Please contact super admin for help with archiving organization.":"Permission refusée : Veuillez contacter le super administrateur pour obtenir de l'aide sur l'organisation de l'archivage.","Permission Denied: Please contact super admin for help with removing domain.":"Permission refusée : Veuillez contacter l'utilisateur de l'organisation pour obtenir de l'aide sur la mise à jour de ce domaine.","Permission Denied: Please contact super admin for help with removing organization.":"Permission refusée : Veuillez contacter le super administrateur pour qu'il vous aide à supprimer l'organisation.","Permission Denied: Please contact super admin for help with scanning this domain.":"Permission refusée : Veuillez contacter le super administrateur pour obtenir de l'aide sur l'analyse de ce domaine.","Permission Denied: Please contact super admin for help with verifying this organization.":"Permission refusée : Veuillez contacter le super administrateur pour qu'il vous aide à vérifier cette organisation.","Permission check error. Unable to request domain information.":"Erreur de vérification des permissions. Impossible de demander des informations sur le domaine.","Permission error, not an admin for this user.":"Erreur de permission, pas d'administrateur pour cet utilisateur.","Permission error: Unable to close other user's account.":"Erreur de permission: Impossible de fermer le compte d'un autre utilisateur.","Permissions error. You do not have sufficient permissions to access this data.":"Erreur de permissions. Vous n'avez pas les autorisations suffisantes pour accéder à ces données.","Phone number has been successfully removed.":"Le numéro de téléphone a été supprimé avec succès.","Phone number has been successfully set, you will receive a verification text message shortly.":"Le numéro de téléphone a été configuré avec succès, vous recevrez bientôt un message de vérification.","Please provide a comment when adding an outside domain.":"Veuillez fournir un commentaire lorsque vous ajoutez un domaine externe.","Profile successfully updated.":"Le profil a été mis à jour avec succès.","Requesting `{amount}` records on the `Affiliation` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `Affiliation` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `DkimFailureTable` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `DkimFailureTable` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `DmarcFailureTable` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `DkimFailureTable` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `DmarcSummaries` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `DmarcSummaries` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `Domain` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `Domain` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `FullPassTable` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `FullPassTable` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `GuidanceTag` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `GuidanceTag` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `Log` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `Log` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `Organization` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `Organization` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `SpfFailureTable` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `SpfFailureTable` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `User` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `User` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `VerifiedDomain` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `VerifiedDomain` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `VerifiedOrganization` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `VerifiedOrganization` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting {amount} records on the `DKIMResults` connection exceeds the `{argSet}` limit of 100 records.":["La demande de ",["amount"]," enregistrements sur la connexion `DKIMResults` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting {amount} records on the `DKIM` connection exceeds the `{argSet}` limit of 100 records.":["La demande de ",["amount"]," enregistrements sur la connexion `DKIM` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting {amount} records on the `DMARC` connection exceeds the `{argSet}` limit of 100 records.":["La demande de ",["amount"]," enregistrements sur la connexion `DMARC` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting {amount} records on the `HTTPS` connection exceeds the `{argSet}` limit of 100 records.":["La demande de ",["amount"]," enregistrements sur la connexion `HTTPS` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting {amount} records on the `SPF` connection exceeds the `{argSet}` limit of 100 records.":["La demande de ",["amount"]," enregistrements sur la connexion `SPF` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting {amount} records on the `SSL` connection exceeds the `{argSet}` limit of 100 records.":["La demande de ",["amount"]," enregistrements sur la connexion `SSL` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Successfully added {domainCount} domain(s) to {0}.":["Ajouté avec succès le(s) domaine(s) ",["domainCount"]," à ",["0"],"."],"Successfully added {domainCount} domains to {0}.":["Ajouté avec succès les domaines ",["domainCount"]," à ",["0"],"."],"Successfully archived organization: {0}.":["Organisation archivée avec succès : ",["0"],"."],"Successfully closed account.":"Le compte a été fermé avec succès.","Successfully dispatched one time scan.":"Un seul balayage a été effectué avec succès.","Successfully dispatched subdomain discovery scan.":"L'analyse de découverte du sous-domaine a été effectuée avec succès.","Successfully email verified account, and set TFA send method to email.":"Réussir à envoyer un email au compte vérifié, et définir la méthode d'envoi de la TFA sur email.","Successfully invited user to organization, and sent notification email.":"L'utilisateur a été invité avec succès à l'organisation et l'email de notification a été envoyé.","Successfully left organization: {0}":["L'organisation a été quittée avec succès: ",["0"]],"Successfully removed domain: {0} from favourites.":["A réussi à supprimer le domaine : ",["0"]," des favoris."],"Successfully removed domain: {0} from {1}.":["A réussi à supprimer le domaine : ",["0"]," de ",["1"],"."],"Successfully removed organization: {0}.":["A réussi à supprimer l'organisation : ",["0"],"."],"Successfully removed user from organization.":"L'utilisateur a été retiré de l'organisation avec succès.","Successfully removed {domainCount} domain(s) from {0}.":["Supprimé avec succès le(s) domaine(s) ",["domainCount"]," de ",["0"],"."],"Successfully removed {domainCount} domains from {0}.":["Suppression réussie des domaines ",["domainCount"]," de ",["0"],"."],"Successfully requested invite to organization, and sent notification email.":"La demande d'invitation à l'organisation a été effectuée avec succès et un courriel de notification a été envoyé.","Successfully sent invitation to service, and organization email.":"Envoi réussi de l'invitation au service, et de l'email de l'organisation.","Successfully signed out.":"J'ai réussi à me déconnecter.","Successfully transferred org: {0} ownership to user: {1}":["A réussi à transférer la propriété de org: ",["0"]," à l'utilisateur: ",["1"]],"Successfully verified organization: {0}.":"Envoi réussi de l'invitation au service, et de l'email de l'organisation.","Successfully verified phone number, and set TFA send method to text.":"Le numéro de téléphone a été vérifié avec succès, et la méthode d'envoi de la TFA a été réglée sur le texte.","Token value incorrect, please sign in again.":"La valeur du jeton est incorrecte, veuillez vous connecter à nouveau.","Too many failed login attempts, please reset your password, and try again.":"Trop de tentatives de connexion ont échoué, veuillez réinitialiser votre mot de passe et réessayer.","Two factor code is incorrect. Please try again.":"Le code à deux facteurs est incorrect. Veuillez réessayer.","Two factor code length is incorrect. Please try again.":"La longueur du code à deux facteurs est incorrecte. Veuillez réessayer.","Unable leave organization. Please try again.":"Impossible de quitter l'organisation. Veuillez réessayer.","Unable to add domains in unknown organization.":"Impossible d'ajouter des domaines dans une organisation inconnue.","Unable to archive organization. Please try again.":"Impossible d'archiver l'organisation. Veuillez réessayer.","Unable to archive unknown organization.":"Impossible d'archiver une organisation inconnue.","Unable to authenticate. Please try again.":"Impossible de s'authentifier. Veuillez réessayer.","Unable to check permission. Please try again.":"Impossible de vérifier l'autorisation. Veuillez réessayer.","Unable to close account of an undefined user.":"Impossible de fermer le compte d'un utilisateur non défini.","Unable to close account. Please try again.":"Impossible de fermer le compte. Veuillez réessayer.","Unable to create domain in unknown organization.":"Impossible de créer un domaine dans une organisation inconnue.","Unable to create domain, organization has already claimed it.":"Impossible de créer le domaine, l'organisation l'a déjà réclamé.","Unable to create domain. Please try again.":"Impossible de créer un domaine. Veuillez réessayer.","Unable to create domains. Please try again.":"Impossible de créer des domaines. Veuillez réessayer.","Unable to create organization. Please try again.":"Impossible de créer une organisation. Veuillez réessayer.","Unable to discover domains for unknown organization.":"Impossible de découvrir les domaines d'une organisation inconnue.","Unable to dispatch one time scan. Please try again.":"Impossible d'envoyer un scan unique. Veuillez réessayer.","Unable to export organization. Please try again.":"Impossible d'exporter l'organisation. Veuillez réessayer.","Unable to favourite domain, user has already favourited it.":"Impossible de favoriser le domaine, l'utilisateur l'a déjà favorisé.","Unable to favourite domain. Please try again.":"Impossible d'accéder au domaine favori. Veuillez réessayer.","Unable to favourite unknown domain.":"Impossible de favoriser le domaine inconnu.","Unable to find Aggregate guidance tag(s). Please try again.":"Impossible de trouver le(s) tag(s) d'orientation des agrégats. Veuillez réessayer.","Unable to find DKIM guidance tag(s). Please try again.":"Impossible de trouver le(s) tag(s) d'orientation DKIM. Veuillez réessayer.","Unable to find DKIM result(s). Please try again.":"Impossible de trouver le(s) résultat(s) DKIM. Veuillez réessayer.","Unable to find DKIM scan(s). Please try again.":"Impossible de trouver le(s) scan(s) DKIM. Veuillez réessayer.","Unable to find DMARC guidance tag(s). Please try again.":"Impossible de trouver le(s) tag(s) d'orientation DMARC. Veuillez réessayer.","Unable to find DMARC scan(s). Please try again.":"Impossible de trouver le(s) scan(s) DMARC. Veuillez réessayer.","Unable to find DMARC summary data. Please try again.":"Impossible de trouver les données de synthèse DMARC. Veuillez réessayer.","Unable to find DNS scan(s). Please try again.":"Impossible de trouver le(s) scan(s) DNS. Veuillez réessayer.","Unable to find HTTPS guidance tag(s). Please try again.":"Impossible de trouver la ou les balises d'orientation HTTPS. Veuillez réessayer.","Unable to find HTTPS scan(s). Please try again.":"Impossible de trouver le(s) scan(s) HTTPS. Veuillez réessayer.","Unable to find SPF guidance tag(s). Please try again.":"Impossible de trouver le(s) tag(s) d'orientation SPF. Veuillez réessayer.","Unable to find SPF scan(s). Please try again.":"Impossible de trouver le(s) scan(s) SPF. Veuillez réessayer.","Unable to find SSL guidance tag(s). Please try again.":"Impossible de trouver le(s) tag(s) d'orientation SSL. Veuillez réessayer.","Unable to find SSL scan(s). Please try again.":"Impossible de trouver le(s) scan(s) SSL. Veuillez réessayer.","Unable to find the requested domain.":"Impossible de trouver le domaine demandé.","Unable to find user affiliation(s). Please try again.":"Impossible de trouver l'affiliation de l'utilisateur (s). Veuillez réessayer.","Unable to find verified organization(s). Please try again.":"Impossible de trouver une ou plusieurs organisations vérifiées. Veuillez réessayer.","Unable to invite user to organization. Please try again.":"Impossible d'inviter un utilisateur dans une organisation. Veuillez réessayer.","Unable to invite user to organization. User is already affiliated with organization.":"Impossible d'inviter un utilisateur dans une organisation. L'utilisateur est déjà affilié à l'organisation.","Unable to invite user to unknown organization.":"Impossible d'inviter un utilisateur à une organisation inconnue.","Unable to invite user. Please try again.":"Impossible d'inviter un utilisateur. Veuillez réessayer.","Unable to invite yourself to an org.":"Impossible de s'inviter à un org.","Unable to leave organization. Please try again.":"Impossible de quitter l'organisation. Veuillez réessayer.","Unable to leave undefined organization.":"Impossible de quitter une organisation non définie.","Unable to load Aggregate guidance tag(s). Please try again.":"Impossible de charger le(s) tag(s) d'orientation des agrégats. Veuillez réessayer.","Unable to load DKIM failure data. Please try again.":"Impossible de charger les données d'échec DKIM. Veuillez réessayer.","Unable to load DKIM guidance tag(s). Please try again.":"Impossible de charger le(s) tag(s) d'orientation DKIM. Veuillez réessayer.","Unable to load DKIM result(s). Please try again.":"Impossible de charger le(s) résultat(s) DKIM. Veuillez réessayer.","Unable to load DKIM scan(s). Please try again.":"Impossible de charger le(s) scan(s) DKIM. Veuillez réessayer.","Unable to load DKIM summary. Please try again.":"Impossible de charger le résumé DKIM. Veuillez réessayer.","Unable to load DMARC failure data. Please try again.":"Impossible de charger les données d'échec DMARC. Veuillez réessayer.","Unable to load DMARC guidance tag(s). Please try again.":"Impossible de charger le(s) tag(s) d'orientation DMARC. Veuillez réessayer.","Unable to load DMARC phase summary. Please try again.":"Impossible de charger le résumé DMARC. Veuillez réessayer.","Unable to load DMARC scan(s). Please try again.":"Impossible de charger le(s) scan(s) DMARC. Veuillez réessayer.","Unable to load DMARC summary data. Please try again.":"Impossible de charger les données de synthèse DMARC. Veuillez réessayer.","Unable to load DMARC summary. Please try again.":"Impossible de charger le résumé DMARC. Veuillez réessayer.","Unable to load DNS scan(s). Please try again.":"Impossible de charger le(s) scan(s) DNS. Veuillez réessayer.","Unable to load HTTPS guidance tag(s). Please try again.":"Impossible de charger la ou les balises d'orientation HTTPS. Veuillez réessayer.","Unable to load HTTPS scan(s). Please try again.":"Impossible de charger le(s) scan(s) HTTPS. Veuillez réessayer.","Unable to load HTTPS summary. Please try again.":"Impossible de charger le résumé HTTPS. Veuillez réessayer.","Unable to load SPF failure data. Please try again.":"Impossible de charger les données d'échec SPF. Veuillez réessayer.","Unable to load SPF guidance tag(s). Please try again.":"Impossible de charger le(s) tag(s) d'orientation SPF. Veuillez réessayer.","Unable to load SPF scan(s). Please try again.":"Impossible de charger le(s) scan(s) SPF. Veuillez réessayer.","Unable to load SPF summary. Please try again.":"Impossible de charger le résumé SPF. Veuillez réessayer.","Unable to load SSL guidance tag(s). Please try again.":"Impossible de charger le(s) tag(s) d'orientation SSL. Veuillez réessayer.","Unable to load SSL scan(s). Please try again.":"Impossible de charger le(s) scan(s) SSL. Veuillez réessayer.","Unable to load SSL summary. Please try again.":"Impossible de charger le résumé SSL. Veuillez réessayer.","Unable to load affiliation information. Please try again.":"Impossible de charger les informations d'affiliation. Veuillez réessayer.","Unable to load affiliation(s). Please try again.":"Impossible de charger l'affiliation (s). Veuillez réessayer.","Unable to load all organization domain statuses. Please try again.":"Impossible de charger tous les statuts de domaine d'organisation. Veuillez réessayer.","Unable to load domain(s). Please try again.":"Impossible de charger le(s) domaine(s). Veuillez réessayer.","Unable to load domain. Please try again.":"Impossible de charger le domaine. Veuillez réessayer.","Unable to load full pass data. Please try again.":"Impossible de charger les données complètes de la passe. Veuillez réessayer.","Unable to load log(s). Please try again.":"Impossible de charger le(s) journal(s). Veuillez réessayer.","Unable to load log. Please try again.":"Impossible de charger le journal. Veuillez réessayer.","Unable to load mail summary. Please try again.":"Impossible de charger le résumé du courrier. Veuillez réessayer.","Unable to load organization domain statuses. Please try again.":"Impossible de charger les statuts des domaines d'organisation. Veuillez réessayer.","Unable to load organization(s). Please try again.":"Impossible de charger l'organisation (s). Veuillez réessayer.","Unable to load owner information. Please try again.":"Impossible de charger les informations sur le propriétaire. Veuillez réessayer.","Unable to load summary. Please try again.":"Impossible de charger le résumé. Veuillez réessayer.","Unable to load tags(s). Please try again.":"Impossible de charger les balises. Veuillez réessayer.","Unable to load user(s). Please try again.":"Impossible de charger le(s) utilisateur(s). Veuillez réessayer.","Unable to load verified domain(s). Please try again.":"Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.","Unable to load verified organization(s). Please try again.":"Impossible de charger le(s) organisme(s) vérifié(s). Veuillez réessayer.","Unable to load web connections summary. Please try again.":"Impossible de charger le résumé des connexions web. Veuillez réessayer.","Unable to load web scan(s). Please try again.":"Impossible de charger le(s) scan(s) web. Veuillez réessayer.","Unable to load web summary. Please try again.":"Impossible de charger le résumé web. Veuillez réessayer.","Unable to query affiliation(s). Please try again.":"Impossible de demander l'affiliation (s). Veuillez réessayer.","Unable to query domain(s). Please try again.":"Impossible d'interroger le(s) domaine(s). Veuillez réessayer.","Unable to query log(s). Please try again.":"Impossible d'interroger le(s) journal(s). Veuillez réessayer.","Unable to query user(s). Please try again.":"Impossible d'interroger le(s) utilisateur(s). Veuillez réessayer.","Unable to refresh tokens, please sign in.":"Impossible de rafraîchir les jetons, veuillez vous connecter.","Unable to remove a user that already does not belong to this organization.":"Impossible de supprimer un utilisateur qui n'appartient déjà plus à cette organisation.","Unable to remove domain from unknown organization.":"Impossible de supprimer le domaine d'une organisation inconnue.","Unable to remove domain. Domain is not part of organization.":"Impossible de supprimer le domaine. Le domaine ne fait pas partie de l'organisation.","Unable to remove domain. Please try again.":"Impossible de supprimer le domaine. Veuillez réessayer.","Unable to remove domains from unknown organization.":"Impossible de supprimer les domaines d'une organisation inconnue.","Unable to remove organization. Please try again.":"Impossible de supprimer l'organisation. Veuillez réessayer.","Unable to remove phone number. Please try again.":"Impossible de supprimer le numéro de téléphone. Veuillez réessayer.","Unable to remove unknown domain.":"Impossible de supprimer un domaine inconnu.","Unable to remove unknown organization.":"Impossible de supprimer une organisation inconnue.","Unable to remove unknown user from organization.":"Impossible de supprimer un utilisateur inconnu de l'organisation.","Unable to remove user from organization.":"Impossible de supprimer un utilisateur de l'organisation.","Unable to remove user from this organization. Please try again.":"Impossible de supprimer l'utilisateur de cette organisation. Veuillez réessayer.","Unable to remove user from unknown organization.":"Impossible de supprimer un utilisateur d'une organisation inconnue.","Unable to request a one time scan on a domain that already has a pending scan.":"Impossible de demander une analyse unique sur un domaine qui a déjà une analyse en cours.","Unable to request a one time scan on an unknown domain.":"Impossible de demander un scan unique sur un domaine inconnu.","Unable to request a one time scan. Please try again.":"Impossible de demander une analyse unique. Veuillez réessayer.","Unable to request a subdomain discovery scan on an invalid domain.":"Impossible de demander un scan de découverte de sous-domaine sur un domaine invalide.","Unable to request a subdomain discovery scan on an unknown domain.":"Impossible de demander une analyse de découverte de sous-domaine sur un domaine inconnu.","Unable to request invite to organization with which you are already affiliated.":"Impossible de demander une invitation à une organisation à laquelle vous êtes déjà affilié.","Unable to request invite to organization with which you have already requested to join.":"Impossible de demander une invitation à une organisation à laquelle vous avez déjà demandé à adhérer.","Unable to request invite to unknown organization.":"Impossible de demander une invitation à une organisation inconnue.","Unable to request invite. Please try again.":"Impossible de demander une invitation. Veuillez réessayer.","Unable to reset password. Please request a new email.":"Impossible de réinitialiser le mot de passe. Veuillez demander un nouvel e-mail.","Unable to reset password. Please try again.":"Impossible de réinitialiser le mot de passe. Veuillez réessayer.","Unable to retrieve DMARC report information for: {domain}":["Impossible de récupérer les informations du rapport DMARC pour : ",["domain"]],"Unable to select DMARC report(s) for this period and year.":"Impossible de sélectionner le(s) rapport(s) DMARC pour cette période et cette année.","Unable to send authentication email. Please try again.":"Impossible d'envoyer l'email d'authentification. Veuillez réessayer.","Unable to send authentication text message. Please try again.":"Impossible d'envoyer un message texte d'authentification. Veuillez réessayer.","Unable to send org invite email. Please try again.":"Impossible d'envoyer l'e-mail d'invitation à l'org. Veuillez réessayer.","Unable to send org invite request email. Please try again.":"Impossible d'envoyer l'email de demande d'invitation à l'org. Veuillez réessayer.","Unable to send password reset email. Please try again.":"Impossible d'envoyer l'email de réinitialisation du mot de passe. Veuillez réessayer.","Unable to send two factor authentication message. Please try again.":"Impossible d'envoyer le message d'authentification à deux facteurs. Veuillez réessayer.","Unable to send verification email. Please try again.":"Impossible d'envoyer l'email de vérification. Veuillez réessayer.","Unable to set phone number, please try again.":"Impossible de définir le numéro de téléphone, veuillez réessayer.","Unable to sign in, please try again.":"Impossible de se connecter, veuillez réessayer.","Unable to sign up, please contact org admin for a new invite.":"Impossible de s'inscrire, veuillez contacter l'administrateur de l'organisation pour obtenir une nouvelle invitation.","Unable to sign up. Please try again.":"Impossible de s'inscrire. Veuillez réessayer.","Unable to transfer organization ownership. Please try again.":"Impossible de transférer la propriété de l'organisation. Veuillez réessayer.","Unable to transfer ownership of a verified organization.":"Impossible de transférer la propriété d'une organisation vérifiée.","Unable to transfer ownership of an org to an undefined user.":"Impossible de transférer la propriété d'un org à un utilisateur non défini.","Unable to transfer ownership of undefined organization.":"Impossible de transférer la propriété d'une organisation non définie.","Unable to transfer ownership to a user outside the org. Please invite the user and try again.":"Impossible de transférer la propriété à un utilisateur extérieur à l'org. Veuillez inviter l'utilisateur et réessayer.","Unable to two factor authenticate. Please try again.":"Impossible de s'authentifier par deux facteurs. Veuillez réessayer.","Unable to unfavourite domain, domain is not favourited.":"Impossible de désactiver le domaine, le domaine n'est pas favorisé.","Unable to unfavourite domain. Please try again.":"Impossible de défavoriser le domaine. Veuillez réessayer.","Unable to unfavourite unknown domain.":"Impossible de défavoriser un domaine inconnu.","Unable to update domain edge. Please try again.":"Impossible de mettre à jour le bord du domaine. Veuillez réessayer.","Unable to update domain in an unknown org.":"Impossible de mettre à jour le domaine dans un org inconnu.","Unable to update domain that does not belong to the given organization.":"Impossible de mettre à jour un domaine qui n'appartient pas à l'organisation donnée.","Unable to update domain. Please try again.":"Impossible de mettre à jour le domaine. Veuillez réessayer.","Unable to update organization. Please try again.":"Impossible de mettre à jour l'organisation. Veuillez réessayer.","Unable to update password, current password does not match. Please try again.":"Impossible de mettre à jour le mot de passe, le mot de passe actuel ne correspond pas. Veuillez réessayer.","Unable to update password, new passwords do not match. Please try again.":"Impossible de mettre à jour le mot de passe, les nouveaux mots de passe ne correspondent pas. Veuillez réessayer.","Unable to update password, passwords do not match requirements. Please try again.":"Impossible de mettre à jour le mot de passe, les mots de passe ne correspondent pas aux exigences. Veuillez réessayer.","Unable to update password. Please try again.":"Impossible de mettre à jour le mot de passe. Veuillez réessayer.","Unable to update profile. Please try again.":"Impossible de mettre à jour le profil. Veuillez réessayer.","Unable to update role: organization unknown.":"Impossible de mettre à jour le rôle : organisation inconnue.","Unable to update role: user does not belong to organization.":"Impossible de mettre à jour le rôle : l'utilisateur n'appartient pas à l'organisation.","Unable to update role: user unknown.":"Impossible de mettre à jour le rôle : utilisateur inconnu.","Unable to update unknown domain.":"Impossible de mettre à jour un domaine inconnu.","Unable to update unknown organization.":"Impossible de mettre à jour une organisation inconnue.","Unable to update user's role. Please try again.":"Impossible de mettre à jour le rôle de l'utilisateur. Veuillez réessayer.","Unable to update your own role.":"Impossible de mettre à jour votre propre rôle.","Unable to verify account. Please request a new email.":"Impossible de vérifier le compte. Veuillez demander un nouvel e-mail.","Unable to verify account. Please try again.":"Impossible de vérifier le compte. Veuillez réessayer.","Unable to verify if user is a super admin, please try again.":"Impossible de vérifier si l'utilisateur est un super administrateur, veuillez réessayer.","Unable to verify if user is an admin, please try again.":"Impossible de vérifier si l'utilisateur est un administrateur, veuillez réessayer.","Unable to verify organization. Please try again.":"Impossible de vérifier l'organisation. Veuillez réessayer.","Unable to verify unknown organization.":"Impossible de vérifier une organisation inconnue.","User could not be queried.":"L'utilisateur n'a pas pu être interrogé.","User role was updated successfully.":"Le rôle de l'utilisateur a été mis à jour avec succès.","Username not available, please try another.":"Le nom d'utilisateur n'est pas disponible, veuillez en essayer un autre.","Verification error. Please activate multi-factor authentication to access content.":"Erreur de vérification. Veuillez activer l'authentification multifactorielle pour accéder au contenu.","Verification error. Please verify your account via email to access content.":"Erreur de vérification. Veuillez vérifier votre compte par e-mail pour accéder au contenu.","You must provide a `first` or `last` value to properly paginate the `Affiliation` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `Affiliation`.","You must provide a `first` or `last` value to properly paginate the `DKIMResults` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `DKIMResults`.","You must provide a `first` or `last` value to properly paginate the `DKIM` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `DKIM`.","You must provide a `first` or `last` value to properly paginate the `DMARC` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `DMARC`.","You must provide a `first` or `last` value to properly paginate the `DkimFailureTable` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `DkimFailureTable`.","You must provide a `first` or `last` value to properly paginate the `DmarcFailureTable` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `DmarcFailureTable`.","You must provide a `first` or `last` value to properly paginate the `DmarcSummaries` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `DmarcSummaries`.","You must provide a `first` or `last` value to properly paginate the `Domain` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `Domain`.","You must provide a `first` or `last` value to properly paginate the `FullPassTable` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `FullPassTable`.","You must provide a `first` or `last` value to properly paginate the `GuidanceTag` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `GuidanceTag`.","You must provide a `first` or `last` value to properly paginate the `HTTPS` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `HTTPS`.","You must provide a `first` or `last` value to properly paginate the `Log` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `Log`.","You must provide a `first` or `last` value to properly paginate the `Organization` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `Organization`.","You must provide a `first` or `last` value to properly paginate the `SPF` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `SPF`.","You must provide a `first` or `last` value to properly paginate the `SSL` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `SSL`.","You must provide a `first` or `last` value to properly paginate the `SpfFailureTable` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `SpfFailureTable`.","You must provide a `first` or `last` value to properly paginate the `User` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `User`.","You must provide a `first` or `last` value to properly paginate the `VerifiedDomain` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `VerifiedDomain`.","You must provide a `first` or `last` value to properly paginate the `VerifiedOrganization` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `VerifiedOrganization`.","You must provide a `limit` value in the range of 1-100 to properly paginate the `DNS` connection.":"Vous devez fournir une valeur `limit` comprise entre 1 et 100 pour paginer correctement la connexion `DNS`.","You must provide a `limit` value in the range of 1-100 to properly paginate the `MXRecord` connection.":"Vous devez fournir une valeur `limit` comprise entre 1 et 100 pour paginer correctement la connexion `MXRecord`.","You must provide a `limit` value in the range of 1-100 to properly paginate the `web` connection.":"Vous devez fournir une valeur `limit` comprise entre 1 et 100 pour paginer correctement la connexion `web`.","You must provide a `limit` value to properly paginate the `DNS` connection.":"Vous devez fournir une valeur `limit` pour paginer correctement la connexion `DNS`.","You must provide a `limit` value to properly paginate the `MXRecord` connection.":"Vous devez fournir une valeur `limit` pour paginer correctement la connexion `MXRecord`.","You must provide a `limit` value to properly paginate the `web` connection.":"Vous devez fournir une valeur `limit` pour paginer correctement la connexion `web`.","You must provide a `period` value to access the `DmarcSummaries` connection.":"Vous devez fournir une valeur `period` pour accéder à la connexion `DmarcSummaries`.","You must provide a `year` value to access the `DmarcSummaries` connection.":"Vous devez fournir une valeur `year` pour accéder à la connexion `DmarcSummaries`.","You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `DNS` connection.":"Vous devez fournir au plus une valeur de méthode de pagination (`before`, `after`, `offset`) pour paginer correctement la connexion `DNS`.","You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `MXRecord` connection.":"Vous devez fournir au plus une valeur de méthode de pagination (`before`, `after`, `offset`) pour paginer correctement la connexion `MXRecord`.","You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `web` connection.":"Vous devez fournir au plus une valeur de méthode de pagination (`before`, `after`, `offset`) pour paginer correctement la connexion `web`.","`{argSet}` must be of type `number` not `{typeSet}`.":["`",["argSet"],"` doit être de type `number` et non `",["typeSet"],"`."],"`{argSet}` on the `Affiliation` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `Affiliation` ne peut être inférieur à zéro."],"`{argSet}` on the `DKIMResults` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `DKIMResults` ne peut être inférieur à zéro."],"`{argSet}` on the `DKIM` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `DKIM` ne peut être inférieur à zéro."],"`{argSet}` on the `DMARC` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `DMARC` ne peut être inférieur à zéro."],"`{argSet}` on the `DkimFailureTable` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `DkimFailureTable` ne peut être inférieur à zéro."],"`{argSet}` on the `DmarcFailureTable` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `DmarcFailureTable` ne peut être inférieur à zéro."],"`{argSet}` on the `DmarcSummaries` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `DmarcSummaries` ne peut être inférieur à zéro."],"`{argSet}` on the `Domain` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `Domain` ne peut être inférieur à zéro."],"`{argSet}` on the `FullPassTable` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `FullPassTable` ne peut être inférieur à zéro."],"`{argSet}` on the `GuidanceTag` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `GuidanceTag` ne peut être inférieure à zéro."],"`{argSet}` on the `HTTPS` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `HTTPS` ne peut être inférieur à zéro."],"`{argSet}` on the `Log` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `Log` ne peut être inférieur à zéro."],"`{argSet}` on the `Organization` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `Organization` ne peut être inférieure à zéro."],"`{argSet}` on the `SPF` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `SPF` ne peut être inférieure à zéro."],"`{argSet}` on the `SSL` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `SSL` ne peut être inférieur à zéro."],"`{argSet}` on the `SpfFailureTable` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `SpfFailureTable` ne peut être inférieur à zéro."],"`{argSet}` on the `User` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `User` ne peut être inférieure à zéro."],"`{argSet}` on the `VerifiedDomain` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `VerifiedDomain` ne peut être inférieur à zéro."],"`{argSet}` on the `VerifiedOrganization` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `VerifiedOrganization` ne peut être inférieur à zéro."]}}; \ No newline at end of file +/*eslint-disable*/module.exports={messages:{"Authentication error. Please sign in.":"Erreur d'authentification. Veuillez vous connecter.","Cannot query additional findings without permission.":"Il n'est pas possible de demander des résultats supplémentaires sans autorisation.","Cannot query affiliations on organization without admin permission or higher.":"Impossible d'interroger les affiliations sur l'organisation sans l'autorisation de l'administrateur ou plus.","Cannot query audit logs on organization without admin permission or higher.":"Impossible d'interroger les journaux d'audit sur l'organisation sans l'autorisation d'administrateur ou plus.","Cannot query dns scan results without permission.":"Impossible d'interroger les résultats de l'analyse DNS sans autorisation.","Cannot query domain selectors without permission.":"Impossible d'interroger les sélecteurs de domaine sans autorisation.","Cannot query web scan results without permission.":"Impossible d'interroger les résultats de l'analyse web sans autorisation.","Email already in use.":"Courriel déjà utilisé.","Error while requesting scan. Please try again.":"Erreur lors de la demande d'analyse. Veuillez réessayer.","If an account with this username is found, a password reset link will be found in your inbox.":"Si un compte avec ce nom d'utilisateur est trouvé, un lien de réinitialisation du mot de passe se trouvera dans votre boîte de réception.","If an account with this username is found, an email verification link will be found in your inbox.":"Si un compte avec ce nom d'utilisateur est trouvé, un lien de vérification par e-mail sera trouvé dans votre boîte de réception.","Incorrect TFA code. Please sign in again.":"Code TFA incorrect. Veuillez vous reconnecter.","Incorrect token value. Please request a new email.":"La valeur du jeton est incorrecte. Veuillez demander un nouvel e-mail.","Incorrect username or password. Please try again.":"Le nom d'utilisateur ou le mot de passe est incorrect. Veuillez réessayer.","Invalid token, please sign in.":"Jeton invalide, veuillez vous connecter.","New passwords do not match.":"Les nouveaux mots de passe ne correspondent pas.","No organization with the provided slug could be found.":"Aucune organisation avec le slug fourni n'a pu être trouvée.","No verified domain with the provided domain could be found.":"Aucun domaine vérifié avec le domaine fourni n'a pu être trouvé.","No verified organization with the provided slug could be found.":"Aucune organisation vérifiée avec le slug fourni n'a pu être trouvée.","Organization has already been verified.":"L'organisation a déjà été vérifiée.","Organization name already in use, please choose another and try again.":"Le nom de l'organisation est déjà utilisé, veuillez en choisir un autre et réessayer.","Organization name already in use. Please try again with a different name.":"Le nom de l'organisation est déjà utilisé. Veuillez réessayer avec un nom différent.","Ownership check error. Unable to request domain information.":"Erreur de vérification de la propriété. Impossible de demander des informations sur le domaine.","Passing both `first` and `last` to paginate the `Affiliation` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `Affiliation` n'est pas supporté.","Passing both `first` and `last` to paginate the `DKIMResults` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `DKIMResults` n'est pas supporté.","Passing both `first` and `last` to paginate the `DKIM` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `DKIMResults` n'est pas supporté.","Passing both `first` and `last` to paginate the `DMARC` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `DMARC` n'est pas supporté.","Passing both `first` and `last` to paginate the `DkimFailureTable` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `DkimFailureTable` n'est pas supporté.","Passing both `first` and `last` to paginate the `DmarcFailureTable` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `DmarcFailureTable` n'est pas supporté.","Passing both `first` and `last` to paginate the `DmarcSummaries` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `DmarcSummaries` n'est pas supporté.","Passing both `first` and `last` to paginate the `Domain` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `Domain` n'est pas supporté.","Passing both `first` and `last` to paginate the `FullPassTable` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `FullPassTable` n'est pas supporté.","Passing both `first` and `last` to paginate the `GuidanceTag` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `GuidanceTag` n'est pas supporté.","Passing both `first` and `last` to paginate the `HTTPS` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `HTTPS` n'est pas supporté.","Passing both `first` and `last` to paginate the `Log` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `Log` n'est pas supporté.","Passing both `first` and `last` to paginate the `Organization` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `Organization` n'est pas supporté.","Passing both `first` and `last` to paginate the `SPF` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `SPF` n'est pas supporté.","Passing both `first` and `last` to paginate the `SSL` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `SSL` n'est pas supporté.","Passing both `first` and `last` to paginate the `SpfFailureTable` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `SpfFailureTable` n'est pas supporté.","Passing both `first` and `last` to paginate the `User` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `User` n'est pas supporté.","Passing both `first` and `last` to paginate the `VerifiedDomain` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `VerifiedDomain` n'est pas supporté.","Passing both `first` and `last` to paginate the `VerifiedOrganization` connection is not supported.":"Passer à la fois `first` et `last` pour paginer la connexion `VerifiedOrganization` n'est pas supporté.","Password does not meet requirements.":"Le mot de passe ne répond pas aux exigences.","Password was successfully reset.":"Le mot de passe a été réinitialisé avec succès.","Password was successfully updated.":"Le mot de passe a été mis à jour avec succès.","Passwords do not match.":"Les mots de passe ne correspondent pas.","Permission Denied: Could not retrieve specified organization.":"Permission refusée : Impossible de récupérer l'organisation spécifiée.","Permission Denied: Multi-factor authentication is required for admin accounts":"Permission refusée : L'authentification multifactorielle est requise pour les comptes admin.","Permission Denied: Please contact org owner to transfer ownership.":"Permission refusée : Veuillez contacter le propriétaire de l'org pour transférer la propriété.","Permission Denied: Please contact organization admin for help with archiving domains.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide sur l'archivage des domaines.","Permission Denied: Please contact organization admin for help with removing domain.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide afin de supprimer le domaine.","Permission Denied: Please contact organization admin for help with removing domains.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide sur la suppression des domaines.","Permission Denied: Please contact organization admin for help with removing organization.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide afin de supprimer l'organisation.","Permission Denied: Please contact organization admin for help with removing users.":"Autorisation refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide sur la suppression des utilisateurs.","Permission Denied: Please contact organization admin for help with updating organization.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide sur la suppression des utilisateurs.","Permission Denied: Please contact organization admin for help with updating user roles.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide sur la mise à jour des rôles des utilisateurs.","Permission Denied: Please contact organization admin for help with user invitations.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide concernant les invitations d'utilisateurs.","Permission Denied: Please contact organization admin for help with user role changes.":"Permission refusée : Veuillez contacter l'administrateur de l'organisation pour obtenir de l'aide sur les changements de rôle des utilisateurs.","Permission Denied: Please contact organization user for help with creating domain.":"Permission refusée : Veuillez contacter l'utilisateur de l'organisation pour obtenir de l'aide sur la création du domaine.","Permission Denied: Please contact organization user for help with creating domains.":"Permission refusée : Veuillez contacter l'utilisateur de l'organisation pour obtenir de l'aide sur la création de domaines.","Permission Denied: Please contact organization user for help with retrieving this domain.":"Permission refusée : Veuillez contacter l'utilisateur de l'organisation pour obtenir de l'aide pour récupérer ce domaine.","Permission Denied: Please contact organization user for help with scanning this domain.":"Permission refusée : Veuillez contacter l'utilisateur de l'organisation pour obtenir de l'aide sur l'analyse de ce domaine.","Permission Denied: Please contact organization user for help with updating this domain.":"Autorisation refusée : Veuillez contacter l'utilisateur de l'organisation pour obtenir de l'aide sur la mise à jour de ce domaine.","Permission Denied: Please contact super admin for help with archiving organization.":"Permission refusée : Veuillez contacter le super administrateur pour obtenir de l'aide sur l'organisation de l'archivage.","Permission Denied: Please contact super admin for help with removing domain.":"Permission refusée : Veuillez contacter l'utilisateur de l'organisation pour obtenir de l'aide sur la mise à jour de ce domaine.","Permission Denied: Please contact super admin for help with removing organization.":"Permission refusée : Veuillez contacter le super administrateur pour qu'il vous aide à supprimer l'organisation.","Permission Denied: Please contact super admin for help with scanning this domain.":"Permission refusée : Veuillez contacter le super administrateur pour obtenir de l'aide sur l'analyse de ce domaine.","Permission Denied: Please contact super admin for help with verifying this organization.":"Permission refusée : Veuillez contacter le super administrateur pour qu'il vous aide à vérifier cette organisation.","Permission check error. Unable to request domain information.":"Erreur de vérification des permissions. Impossible de demander des informations sur le domaine.","Permission error, not an admin for this user.":"Erreur de permission, pas d'administrateur pour cet utilisateur.","Permission error: Unable to close other user's account.":"Erreur de permission: Impossible de fermer le compte d'un autre utilisateur.","Permissions error. You do not have sufficient permissions to access this data.":"Erreur de permissions. Vous n'avez pas les autorisations suffisantes pour accéder à ces données.","Phone number has been successfully removed.":"Le numéro de téléphone a été supprimé avec succès.","Phone number has been successfully set, you will receive a verification text message shortly.":"Le numéro de téléphone a été configuré avec succès, vous recevrez bientôt un message de vérification.","Please provide a comment when adding an outside domain.":"Veuillez fournir un commentaire lorsque vous ajoutez un domaine externe.","Profile successfully updated.":"Le profil a été mis à jour avec succès.","Requesting `{amount}` records on the `Affiliation` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `Affiliation` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `DkimFailureTable` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `DkimFailureTable` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `DmarcFailureTable` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `DkimFailureTable` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `DmarcSummaries` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `DmarcSummaries` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `Domain` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `Domain` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `FullPassTable` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `FullPassTable` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `GuidanceTag` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `GuidanceTag` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `Log` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `Log` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `Organization` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `Organization` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `SpfFailureTable` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `SpfFailureTable` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `User` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `User` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `VerifiedDomain` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `VerifiedDomain` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting `{amount}` records on the `VerifiedOrganization` connection exceeds the `{argSet}` limit of 100 records.":["La demande d'enregistrements `",["amount"],"` sur la connexion `VerifiedOrganization` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting {amount} records on the `DKIMResults` connection exceeds the `{argSet}` limit of 100 records.":["La demande de ",["amount"]," enregistrements sur la connexion `DKIMResults` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting {amount} records on the `DKIM` connection exceeds the `{argSet}` limit of 100 records.":["La demande de ",["amount"]," enregistrements sur la connexion `DKIM` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting {amount} records on the `DMARC` connection exceeds the `{argSet}` limit of 100 records.":["La demande de ",["amount"]," enregistrements sur la connexion `DMARC` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting {amount} records on the `HTTPS` connection exceeds the `{argSet}` limit of 100 records.":["La demande de ",["amount"]," enregistrements sur la connexion `HTTPS` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting {amount} records on the `SPF` connection exceeds the `{argSet}` limit of 100 records.":["La demande de ",["amount"]," enregistrements sur la connexion `SPF` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Requesting {amount} records on the `SSL` connection exceeds the `{argSet}` limit of 100 records.":["La demande de ",["amount"]," enregistrements sur la connexion `SSL` dépasse la limite `",["argSet"],"` de 100 enregistrements."],"Successfully added {domainCount} domain(s) to {0}.":["Ajouté avec succès le(s) domaine(s) ",["domainCount"]," à ",["0"],"."],"Successfully added {domainCount} domains to {0}.":["Ajouté avec succès les domaines ",["domainCount"]," à ",["0"],"."],"Successfully archived organization: {0}.":["Organisation archivée avec succès : ",["0"],"."],"Successfully closed account.":"Le compte a été fermé avec succès.","Successfully dispatched one time scan.":"Un seul balayage a été effectué avec succès.","Successfully dispatched subdomain discovery scan.":"L'analyse de découverte du sous-domaine a été effectuée avec succès.","Successfully email verified account, and set TFA send method to email.":"Réussir à envoyer un email au compte vérifié, et définir la méthode d'envoi de la TFA sur email.","Successfully invited user to organization, and sent notification email.":"L'utilisateur a été invité avec succès à l'organisation et l'email de notification a été envoyé.","Successfully left organization: {0}":["L'organisation a été quittée avec succès: ",["0"]],"Successfully removed domain: {0} from favourites.":["A réussi à supprimer le domaine : ",["0"]," des favoris."],"Successfully removed domain: {0} from {1}.":["A réussi à supprimer le domaine : ",["0"]," de ",["1"],"."],"Successfully removed organization: {0}.":["A réussi à supprimer l'organisation : ",["0"],"."],"Successfully removed user from organization.":"L'utilisateur a été retiré de l'organisation avec succès.","Successfully removed {domainCount} domain(s) from {0}.":["Supprimé avec succès le(s) domaine(s) ",["domainCount"]," de ",["0"],"."],"Successfully removed {domainCount} domains from {0}.":["Suppression réussie des domaines ",["domainCount"]," de ",["0"],"."],"Successfully requested invite to organization, and sent notification email.":"La demande d'invitation à l'organisation a été effectuée avec succès et un courriel de notification a été envoyé.","Successfully sent invitation to service, and organization email.":"Envoi réussi de l'invitation au service, et de l'email de l'organisation.","Successfully signed out.":"J'ai réussi à me déconnecter.","Successfully transferred org: {0} ownership to user: {1}":["A réussi à transférer la propriété de org: ",["0"]," à l'utilisateur: ",["1"]],"Successfully verified organization: {0}.":"Envoi réussi de l'invitation au service, et de l'email de l'organisation.","Successfully verified phone number, and set TFA send method to text.":"Le numéro de téléphone a été vérifié avec succès, et la méthode d'envoi de la TFA a été réglée sur le texte.","Token value incorrect, please sign in again.":"La valeur du jeton est incorrecte, veuillez vous connecter à nouveau.","Too many failed login attempts, please reset your password, and try again.":"Trop de tentatives de connexion ont échoué, veuillez réinitialiser votre mot de passe et réessayer.","Two factor code is incorrect. Please try again.":"Le code à deux facteurs est incorrect. Veuillez réessayer.","Two factor code length is incorrect. Please try again.":"La longueur du code à deux facteurs est incorrecte. Veuillez réessayer.","Unable leave organization. Please try again.":"Impossible de quitter l'organisation. Veuillez réessayer.","Unable to add domains in unknown organization.":"Impossible d'ajouter des domaines dans une organisation inconnue.","Unable to archive organization. Please try again.":"Impossible d'archiver l'organisation. Veuillez réessayer.","Unable to archive unknown organization.":"Impossible d'archiver une organisation inconnue.","Unable to authenticate. Please try again.":"Impossible de s'authentifier. Veuillez réessayer.","Unable to check permission. Please try again.":"Impossible de vérifier l'autorisation. Veuillez réessayer.","Unable to close account of an undefined user.":"Impossible de fermer le compte d'un utilisateur non défini.","Unable to close account. Please try again.":"Impossible de fermer le compte. Veuillez réessayer.","Unable to create domain in unknown organization.":"Impossible de créer un domaine dans une organisation inconnue.","Unable to create domain, organization has already claimed it.":"Impossible de créer le domaine, l'organisation l'a déjà réclamé.","Unable to create domain. Please try again.":"Impossible de créer un domaine. Veuillez réessayer.","Unable to create domains. Please try again.":"Impossible de créer des domaines. Veuillez réessayer.","Unable to create organization. Please try again.":"Impossible de créer une organisation. Veuillez réessayer.","Unable to discover domains for unknown organization.":"Impossible de découvrir les domaines d'une organisation inconnue.","Unable to dispatch one time scan. Please try again.":"Impossible d'envoyer un scan unique. Veuillez réessayer.","Unable to export organization. Please try again.":"Impossible d'exporter l'organisation. Veuillez réessayer.","Unable to favourite domain, user has already favourited it.":"Impossible de favoriser le domaine, l'utilisateur l'a déjà favorisé.","Unable to favourite domain. Please try again.":"Impossible d'accéder au domaine favori. Veuillez réessayer.","Unable to favourite unknown domain.":"Impossible de favoriser le domaine inconnu.","Unable to find Aggregate guidance tag(s). Please try again.":"Impossible de trouver le(s) tag(s) d'orientation des agrégats. Veuillez réessayer.","Unable to find DKIM guidance tag(s). Please try again.":"Impossible de trouver le(s) tag(s) d'orientation DKIM. Veuillez réessayer.","Unable to find DKIM result(s). Please try again.":"Impossible de trouver le(s) résultat(s) DKIM. Veuillez réessayer.","Unable to find DKIM scan(s). Please try again.":"Impossible de trouver le(s) scan(s) DKIM. Veuillez réessayer.","Unable to find DMARC guidance tag(s). Please try again.":"Impossible de trouver le(s) tag(s) d'orientation DMARC. Veuillez réessayer.","Unable to find DMARC scan(s). Please try again.":"Impossible de trouver le(s) scan(s) DMARC. Veuillez réessayer.","Unable to find DMARC summary data. Please try again.":"Impossible de trouver les données de synthèse DMARC. Veuillez réessayer.","Unable to find DNS scan(s). Please try again.":"Impossible de trouver le(s) scan(s) DNS. Veuillez réessayer.","Unable to find HTTPS guidance tag(s). Please try again.":"Impossible de trouver la ou les balises d'orientation HTTPS. Veuillez réessayer.","Unable to find HTTPS scan(s). Please try again.":"Impossible de trouver le(s) scan(s) HTTPS. Veuillez réessayer.","Unable to find SPF guidance tag(s). Please try again.":"Impossible de trouver le(s) tag(s) d'orientation SPF. Veuillez réessayer.","Unable to find SPF scan(s). Please try again.":"Impossible de trouver le(s) scan(s) SPF. Veuillez réessayer.","Unable to find SSL guidance tag(s). Please try again.":"Impossible de trouver le(s) tag(s) d'orientation SSL. Veuillez réessayer.","Unable to find SSL scan(s). Please try again.":"Impossible de trouver le(s) scan(s) SSL. Veuillez réessayer.","Unable to find the requested domain.":"Impossible de trouver le domaine demandé.","Unable to find user affiliation(s). Please try again.":"Impossible de trouver l'affiliation de l'utilisateur (s). Veuillez réessayer.","Unable to find verified organization(s). Please try again.":"Impossible de trouver une ou plusieurs organisations vérifiées. Veuillez réessayer.","Unable to invite user to organization. Please try again.":"Impossible d'inviter un utilisateur dans une organisation. Veuillez réessayer.","Unable to invite user to organization. User is already affiliated with organization.":"Impossible d'inviter un utilisateur dans une organisation. L'utilisateur est déjà affilié à l'organisation.","Unable to invite user to unknown organization.":"Impossible d'inviter un utilisateur à une organisation inconnue.","Unable to invite user. Please try again.":"Impossible d'inviter un utilisateur. Veuillez réessayer.","Unable to invite yourself to an org.":"Impossible de s'inviter à un org.","Unable to leave organization. Please try again.":"Impossible de quitter l'organisation. Veuillez réessayer.","Unable to leave undefined organization.":"Impossible de quitter une organisation non définie.","Unable to load Aggregate guidance tag(s). Please try again.":"Impossible de charger le(s) tag(s) d'orientation des agrégats. Veuillez réessayer.","Unable to load DKIM failure data. Please try again.":"Impossible de charger les données d'échec DKIM. Veuillez réessayer.","Unable to load DKIM guidance tag(s). Please try again.":"Impossible de charger le(s) tag(s) d'orientation DKIM. Veuillez réessayer.","Unable to load DKIM result(s). Please try again.":"Impossible de charger le(s) résultat(s) DKIM. Veuillez réessayer.","Unable to load DKIM scan(s). Please try again.":"Impossible de charger le(s) scan(s) DKIM. Veuillez réessayer.","Unable to load DKIM summary. Please try again.":"Impossible de charger le résumé DKIM. Veuillez réessayer.","Unable to load DMARC failure data. Please try again.":"Impossible de charger les données d'échec DMARC. Veuillez réessayer.","Unable to load DMARC guidance tag(s). Please try again.":"Impossible de charger le(s) tag(s) d'orientation DMARC. Veuillez réessayer.","Unable to load DMARC phase summary. Please try again.":"Impossible de charger le résumé DMARC. Veuillez réessayer.","Unable to load DMARC scan(s). Please try again.":"Impossible de charger le(s) scan(s) DMARC. Veuillez réessayer.","Unable to load DMARC summary data. Please try again.":"Impossible de charger les données de synthèse DMARC. Veuillez réessayer.","Unable to load DMARC summary. Please try again.":"Impossible de charger le résumé DMARC. Veuillez réessayer.","Unable to load DNS scan(s). Please try again.":"Impossible de charger le(s) scan(s) DNS. Veuillez réessayer.","Unable to load HTTPS guidance tag(s). Please try again.":"Impossible de charger la ou les balises d'orientation HTTPS. Veuillez réessayer.","Unable to load HTTPS scan(s). Please try again.":"Impossible de charger le(s) scan(s) HTTPS. Veuillez réessayer.","Unable to load HTTPS summary. Please try again.":"Impossible de charger le résumé HTTPS. Veuillez réessayer.","Unable to load SPF failure data. Please try again.":"Impossible de charger les données d'échec SPF. Veuillez réessayer.","Unable to load SPF guidance tag(s). Please try again.":"Impossible de charger le(s) tag(s) d'orientation SPF. Veuillez réessayer.","Unable to load SPF scan(s). Please try again.":"Impossible de charger le(s) scan(s) SPF. Veuillez réessayer.","Unable to load SPF summary. Please try again.":"Impossible de charger le résumé SPF. Veuillez réessayer.","Unable to load SSL guidance tag(s). Please try again.":"Impossible de charger le(s) tag(s) d'orientation SSL. Veuillez réessayer.","Unable to load SSL scan(s). Please try again.":"Impossible de charger le(s) scan(s) SSL. Veuillez réessayer.","Unable to load SSL summary. Please try again.":"Impossible de charger le résumé SSL. Veuillez réessayer.","Unable to load additional findings. Please try again.":"Impossible de charger des résultats supplémentaires. Veuillez réessayer.","Unable to load affiliation information. Please try again.":"Impossible de charger les informations d'affiliation. Veuillez réessayer.","Unable to load affiliation(s). Please try again.":"Impossible de charger l'affiliation (s). Veuillez réessayer.","Unable to load all organization domain statuses. Please try again.":"Impossible de charger tous les statuts de domaine d'organisation. Veuillez réessayer.","Unable to load chart summary data. Please try again.":"Impossible de charger les données du résumé du graphique. Veuillez réessayer.","Unable to load domain selector(s). Please try again.":"Impossible de charger le(s) sélecteur(s) de domaine. Veuillez réessayer.","Unable to load domain(s). Please try again.":"Impossible de charger le(s) domaine(s). Veuillez réessayer.","Unable to load domain. Please try again.":"Impossible de charger le domaine. Veuillez réessayer.","Unable to load full pass data. Please try again.":"Impossible de charger les données complètes de la passe. Veuillez réessayer.","Unable to load log(s). Please try again.":"Impossible de charger le(s) journal(s). Veuillez réessayer.","Unable to load log. Please try again.":"Impossible de charger le journal. Veuillez réessayer.","Unable to load mail summary. Please try again.":"Impossible de charger le résumé du courrier. Veuillez réessayer.","Unable to load organization domain statuses. Please try again.":"Impossible de charger les statuts des domaines d'organisation. Veuillez réessayer.","Unable to load organization summary data. Please try again.":"Impossible de charger les données de synthèse de l'organisation. Veuillez réessayer.","Unable to load organization(s). Please try again.":"Impossible de charger l'organisation (s). Veuillez réessayer.","Unable to load owner information. Please try again.":"Impossible de charger les informations sur le propriétaire. Veuillez réessayer.","Unable to load summary. Please try again.":"Impossible de charger le résumé. Veuillez réessayer.","Unable to load tags(s). Please try again.":"Impossible de charger les balises. Veuillez réessayer.","Unable to load user(s). Please try again.":"Impossible de charger le(s) utilisateur(s). Veuillez réessayer.","Unable to load verified domain(s). Please try again.":"Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.","Unable to load verified organization(s). Please try again.":"Impossible de charger le(s) organisme(s) vérifié(s). Veuillez réessayer.","Unable to load verified rua domains. Please try again.":"Impossible de charger les domaines rua vérifiés. Veuillez réessayer.","Unable to load web connections summary. Please try again.":"Impossible de charger le résumé des connexions web. Veuillez réessayer.","Unable to load web scan(s). Please try again.":"Impossible de charger le(s) scan(s) web. Veuillez réessayer.","Unable to load web summary. Please try again.":"Impossible de charger le résumé web. Veuillez réessayer.","Unable to query affiliation(s). Please try again.":"Impossible de demander l'affiliation (s). Veuillez réessayer.","Unable to query domain(s). Please try again.":"Impossible d'interroger le(s) domaine(s). Veuillez réessayer.","Unable to query log(s). Please try again.":"Impossible d'interroger le(s) journal(s). Veuillez réessayer.","Unable to query user(s). Please try again.":"Impossible d'interroger le(s) utilisateur(s). Veuillez réessayer.","Unable to refresh tokens, please sign in.":"Impossible de rafraîchir les jetons, veuillez vous connecter.","Unable to remove a user that already does not belong to this organization.":"Impossible de supprimer un utilisateur qui n'appartient déjà plus à cette organisation.","Unable to remove domain from unknown organization.":"Impossible de supprimer le domaine d'une organisation inconnue.","Unable to remove domain. Domain is not part of organization.":"Impossible de supprimer le domaine. Le domaine ne fait pas partie de l'organisation.","Unable to remove domain. Please try again.":"Impossible de supprimer le domaine. Veuillez réessayer.","Unable to remove domains from unknown organization.":"Impossible de supprimer les domaines d'une organisation inconnue.","Unable to remove organization. Please try again.":"Impossible de supprimer l'organisation. Veuillez réessayer.","Unable to remove phone number. Please try again.":"Impossible de supprimer le numéro de téléphone. Veuillez réessayer.","Unable to remove unknown domain.":"Impossible de supprimer un domaine inconnu.","Unable to remove unknown organization.":"Impossible de supprimer une organisation inconnue.","Unable to remove unknown user from organization.":"Impossible de supprimer un utilisateur inconnu de l'organisation.","Unable to remove user from organization.":"Impossible de supprimer un utilisateur de l'organisation.","Unable to remove user from this organization. Please try again.":"Impossible de supprimer l'utilisateur de cette organisation. Veuillez réessayer.","Unable to remove user from unknown organization.":"Impossible de supprimer un utilisateur d'une organisation inconnue.","Unable to request a one time scan on a domain that already has a pending scan.":"Impossible de demander une analyse unique sur un domaine qui a déjà une analyse en cours.","Unable to request a one time scan on an unknown domain.":"Impossible de demander un scan unique sur un domaine inconnu.","Unable to request a one time scan. Please try again.":"Impossible de demander une analyse unique. Veuillez réessayer.","Unable to request a subdomain discovery scan on an invalid domain.":"Impossible de demander un scan de découverte de sous-domaine sur un domaine invalide.","Unable to request a subdomain discovery scan on an unknown domain.":"Impossible de demander une analyse de découverte de sous-domaine sur un domaine inconnu.","Unable to request invite to organization with which you are already affiliated.":"Impossible de demander une invitation à une organisation à laquelle vous êtes déjà affilié.","Unable to request invite to organization with which you have already requested to join.":"Impossible de demander une invitation à une organisation à laquelle vous avez déjà demandé à adhérer.","Unable to request invite to unknown organization.":"Impossible de demander une invitation à une organisation inconnue.","Unable to request invite. Please try again.":"Impossible de demander une invitation. Veuillez réessayer.","Unable to reset password. Please request a new email.":"Impossible de réinitialiser le mot de passe. Veuillez demander un nouvel e-mail.","Unable to reset password. Please try again.":"Impossible de réinitialiser le mot de passe. Veuillez réessayer.","Unable to retrieve DMARC report information for: {domain}":["Impossible de récupérer les informations du rapport DMARC pour : ",["domain"]],"Unable to select DMARC report(s) for this period and year.":"Impossible de sélectionner le(s) rapport(s) DMARC pour cette période et cette année.","Unable to send authentication email. Please try again.":"Impossible d'envoyer l'email d'authentification. Veuillez réessayer.","Unable to send authentication text message. Please try again.":"Impossible d'envoyer un message texte d'authentification. Veuillez réessayer.","Unable to send org invite email. Please try again.":"Impossible d'envoyer l'e-mail d'invitation à l'org. Veuillez réessayer.","Unable to send org invite request email. Please try again.":"Impossible d'envoyer l'email de demande d'invitation à l'org. Veuillez réessayer.","Unable to send password reset email. Please try again.":"Impossible d'envoyer l'email de réinitialisation du mot de passe. Veuillez réessayer.","Unable to send two factor authentication message. Please try again.":"Impossible d'envoyer le message d'authentification à deux facteurs. Veuillez réessayer.","Unable to send verification email. Please try again.":"Impossible d'envoyer l'email de vérification. Veuillez réessayer.","Unable to set phone number, please try again.":"Impossible de définir le numéro de téléphone, veuillez réessayer.","Unable to sign in, please try again.":"Impossible de se connecter, veuillez réessayer.","Unable to sign up, please contact org admin for a new invite.":"Impossible de s'inscrire, veuillez contacter l'administrateur de l'organisation pour obtenir une nouvelle invitation.","Unable to sign up. Please try again.":"Impossible de s'inscrire. Veuillez réessayer.","Unable to transfer organization ownership. Please try again.":"Impossible de transférer la propriété de l'organisation. Veuillez réessayer.","Unable to transfer ownership of a verified organization.":"Impossible de transférer la propriété d'une organisation vérifiée.","Unable to transfer ownership of an org to an undefined user.":"Impossible de transférer la propriété d'un org à un utilisateur non défini.","Unable to transfer ownership of undefined organization.":"Impossible de transférer la propriété d'une organisation non définie.","Unable to transfer ownership to a user outside the org. Please invite the user and try again.":"Impossible de transférer la propriété à un utilisateur extérieur à l'org. Veuillez inviter l'utilisateur et réessayer.","Unable to two factor authenticate. Please try again.":"Impossible de s'authentifier par deux facteurs. Veuillez réessayer.","Unable to unfavourite domain, domain is not favourited.":"Impossible de désactiver le domaine, le domaine n'est pas favorisé.","Unable to unfavourite domain. Please try again.":"Impossible de défavoriser le domaine. Veuillez réessayer.","Unable to unfavourite unknown domain.":"Impossible de défavoriser un domaine inconnu.","Unable to update domain edge. Please try again.":"Impossible de mettre à jour le bord du domaine. Veuillez réessayer.","Unable to update domain in an unknown org.":"Impossible de mettre à jour le domaine dans un org inconnu.","Unable to update domain that does not belong to the given organization.":"Impossible de mettre à jour un domaine qui n'appartient pas à l'organisation donnée.","Unable to update domain. Please try again.":"Impossible de mettre à jour le domaine. Veuillez réessayer.","Unable to update organization. Please try again.":"Impossible de mettre à jour l'organisation. Veuillez réessayer.","Unable to update password, current password does not match. Please try again.":"Impossible de mettre à jour le mot de passe, le mot de passe actuel ne correspond pas. Veuillez réessayer.","Unable to update password, new passwords do not match. Please try again.":"Impossible de mettre à jour le mot de passe, les nouveaux mots de passe ne correspondent pas. Veuillez réessayer.","Unable to update password, passwords do not match requirements. Please try again.":"Impossible de mettre à jour le mot de passe, les mots de passe ne correspondent pas aux exigences. Veuillez réessayer.","Unable to update password. Please try again.":"Impossible de mettre à jour le mot de passe. Veuillez réessayer.","Unable to update profile. Please try again.":"Impossible de mettre à jour le profil. Veuillez réessayer.","Unable to update role: organization unknown.":"Impossible de mettre à jour le rôle : organisation inconnue.","Unable to update role: user does not belong to organization.":"Impossible de mettre à jour le rôle : l'utilisateur n'appartient pas à l'organisation.","Unable to update role: user unknown.":"Impossible de mettre à jour le rôle : utilisateur inconnu.","Unable to update unknown domain.":"Impossible de mettre à jour un domaine inconnu.","Unable to update unknown organization.":"Impossible de mettre à jour une organisation inconnue.","Unable to update user's role. Please try again.":"Impossible de mettre à jour le rôle de l'utilisateur. Veuillez réessayer.","Unable to update your own role.":"Impossible de mettre à jour votre propre rôle.","Unable to verify account. Please request a new email.":"Impossible de vérifier le compte. Veuillez demander un nouvel e-mail.","Unable to verify account. Please try again.":"Impossible de vérifier le compte. Veuillez réessayer.","Unable to verify if user is a super admin, please try again.":"Impossible de vérifier si l'utilisateur est un super administrateur, veuillez réessayer.","Unable to verify if user is an admin, please try again.":"Impossible de vérifier si l'utilisateur est un administrateur, veuillez réessayer.","Unable to verify organization. Please try again.":"Impossible de vérifier l'organisation. Veuillez réessayer.","Unable to verify unknown organization.":"Impossible de vérifier une organisation inconnue.","User could not be queried.":"L'utilisateur n'a pas pu être interrogé.","User role was updated successfully.":"Le rôle de l'utilisateur a été mis à jour avec succès.","Username not available, please try another.":"Le nom d'utilisateur n'est pas disponible, veuillez en essayer un autre.","Verification error. Please activate multi-factor authentication to access content.":"Erreur de vérification. Veuillez activer l'authentification multifactorielle pour accéder au contenu.","Verification error. Please verify your account via email to access content.":"Erreur de vérification. Veuillez vérifier votre compte par e-mail pour accéder au contenu.","You must provide a `domainId` to retrieve a domain's additional findings.":"Vous devez fournir un `domainId` pour récupérer les résultats supplémentaires d'un domaine.","You must provide a `first` or `last` value to properly paginate the `Affiliation` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `Affiliation`.","You must provide a `first` or `last` value to properly paginate the `DKIMResults` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `DKIMResults`.","You must provide a `first` or `last` value to properly paginate the `DKIM` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `DKIM`.","You must provide a `first` or `last` value to properly paginate the `DMARC` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `DMARC`.","You must provide a `first` or `last` value to properly paginate the `DkimFailureTable` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `DkimFailureTable`.","You must provide a `first` or `last` value to properly paginate the `DmarcFailureTable` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `DmarcFailureTable`.","You must provide a `first` or `last` value to properly paginate the `DmarcSummaries` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `DmarcSummaries`.","You must provide a `first` or `last` value to properly paginate the `Domain` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `Domain`.","You must provide a `first` or `last` value to properly paginate the `FullPassTable` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `FullPassTable`.","You must provide a `first` or `last` value to properly paginate the `GuidanceTag` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `GuidanceTag`.","You must provide a `first` or `last` value to properly paginate the `HTTPS` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `HTTPS`.","You must provide a `first` or `last` value to properly paginate the `Log` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `Log`.","You must provide a `first` or `last` value to properly paginate the `Organization` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `Organization`.","You must provide a `first` or `last` value to properly paginate the `SPF` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `SPF`.","You must provide a `first` or `last` value to properly paginate the `SSL` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `SSL`.","You must provide a `first` or `last` value to properly paginate the `SpfFailureTable` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `SpfFailureTable`.","You must provide a `first` or `last` value to properly paginate the `User` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `User`.","You must provide a `first` or `last` value to properly paginate the `VerifiedDomain` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `VerifiedDomain`.","You must provide a `first` or `last` value to properly paginate the `VerifiedOrganization` connection.":"Vous devez fournir une valeur `first` ou `last` pour paginer correctement la connexion `VerifiedOrganization`.","You must provide a `limit` value in the range of 1-100 to properly paginate the `DNS` connection.":"Vous devez fournir une valeur `limit` comprise entre 1 et 100 pour paginer correctement la connexion `DNS`.","You must provide a `limit` value in the range of 1-100 to properly paginate the `MXRecord` connection.":"Vous devez fournir une valeur `limit` comprise entre 1 et 100 pour paginer correctement la connexion `MXRecord`.","You must provide a `limit` value in the range of 1-100 to properly paginate the `web` connection.":"Vous devez fournir une valeur `limit` comprise entre 1 et 100 pour paginer correctement la connexion `web`.","You must provide a `limit` value to properly paginate the `DNS` connection.":"Vous devez fournir une valeur `limit` pour paginer correctement la connexion `DNS`.","You must provide a `limit` value to properly paginate the `MXRecord` connection.":"Vous devez fournir une valeur `limit` pour paginer correctement la connexion `MXRecord`.","You must provide a `limit` value to properly paginate the `web` connection.":"Vous devez fournir une valeur `limit` pour paginer correctement la connexion `web`.","You must provide a `period` value to access the `ChartSummaries` connection.":"Vous devez fournir une valeur `period` pour accéder à la connexion `ChartSummaries`.","You must provide a `period` value to access the `DmarcSummaries` connection.":"Vous devez fournir une valeur `period` pour accéder à la connexion `DmarcSummaries`.","You must provide a `period` value to access the `OrganizationSummaries` connection.":"Vous devez fournir une valeur `period` pour accéder à la connexion `OrganizationSummaries`.","You must provide a `year` value to access the `ChartSummaries` connection.":"Vous devez fournir une valeur `year` pour accéder à la connexion `ChartSummaries`.","You must provide a `year` value to access the `DmarcSummaries` connection.":"Vous devez fournir une valeur `year` pour accéder à la connexion `DmarcSummaries`.","You must provide a `year` value to access the `OrganizationSummaries` connection.":"Vous devez fournir une valeur `year` pour accéder à la connexion `OrganizationSummaries`.","You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `DNS` connection.":"Vous devez fournir au plus une valeur de méthode de pagination (`before`, `after`, `offset`) pour paginer correctement la connexion `DNS`.","You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `MXRecord` connection.":"Vous devez fournir au plus une valeur de méthode de pagination (`before`, `after`, `offset`) pour paginer correctement la connexion `MXRecord`.","You must provide at most one pagination method (`before`, `after`, `offset`) value to properly paginate the `web` connection.":"Vous devez fournir au plus une valeur de méthode de pagination (`before`, `after`, `offset`) pour paginer correctement la connexion `web`.","`{argSet}` must be of type `number` not `{typeSet}`.":["`",["argSet"],"` doit être de type `number` et non `",["typeSet"],"`."],"`{argSet}` on the `Affiliation` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `Affiliation` ne peut être inférieur à zéro."],"`{argSet}` on the `DKIMResults` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `DKIMResults` ne peut être inférieur à zéro."],"`{argSet}` on the `DKIM` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `DKIM` ne peut être inférieur à zéro."],"`{argSet}` on the `DMARC` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `DMARC` ne peut être inférieur à zéro."],"`{argSet}` on the `DkimFailureTable` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `DkimFailureTable` ne peut être inférieur à zéro."],"`{argSet}` on the `DmarcFailureTable` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `DmarcFailureTable` ne peut être inférieur à zéro."],"`{argSet}` on the `DmarcSummaries` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `DmarcSummaries` ne peut être inférieur à zéro."],"`{argSet}` on the `Domain` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `Domain` ne peut être inférieur à zéro."],"`{argSet}` on the `FullPassTable` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `FullPassTable` ne peut être inférieur à zéro."],"`{argSet}` on the `GuidanceTag` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `GuidanceTag` ne peut être inférieure à zéro."],"`{argSet}` on the `HTTPS` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `HTTPS` ne peut être inférieur à zéro."],"`{argSet}` on the `Log` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `Log` ne peut être inférieur à zéro."],"`{argSet}` on the `Organization` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `Organization` ne peut être inférieure à zéro."],"`{argSet}` on the `SPF` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `SPF` ne peut être inférieure à zéro."],"`{argSet}` on the `SSL` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `SSL` ne peut être inférieur à zéro."],"`{argSet}` on the `SpfFailureTable` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `SpfFailureTable` ne peut être inférieur à zéro."],"`{argSet}` on the `User` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `User` ne peut être inférieure à zéro."],"`{argSet}` on the `VerifiedDomain` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `VerifiedDomain` ne peut être inférieur à zéro."],"`{argSet}` on the `VerifiedOrganization` connection cannot be less than zero.":["`",["argSet"],"` sur la connexion `VerifiedOrganization` ne peut être inférieur à zéro."]}}; \ No newline at end of file diff --git a/api/src/organization/loaders/__tests__/load-organization-by-key.test.js b/api/src/organization/loaders/__tests__/load-organization-by-key.test.js index 6003e9f1a4..b733d54434 100644 --- a/api/src/organization/loaders/__tests__/load-organization-by-key.test.js +++ b/api/src/organization/loaders/__tests__/load-organization-by-key.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' @@ -23,16 +24,16 @@ describe('given a loadOrgByKey dataloader', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, - schema: dbschema, - })) + schema: dbschema, + })) }) beforeEach(async () => { await collections.organizations.save({ @@ -243,9 +244,7 @@ describe('given a loadOrgByKey dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadOrgByKey({ query: mockedQuery, language: 'en', @@ -256,9 +255,7 @@ describe('given a loadOrgByKey dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error('Unable to load organization(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load organization(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -284,9 +281,7 @@ describe('given a loadOrgByKey dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error('Unable to load organization(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load organization(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -312,9 +307,7 @@ describe('given a loadOrgByKey dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadOrgByKey({ query: mockedQuery, language: 'fr', @@ -325,11 +318,7 @@ describe('given a loadOrgByKey dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger l'organisation (s). Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger l'organisation (s). Veuillez réessayer.")) } expect(consoleOutput).toEqual([ @@ -355,11 +344,7 @@ describe('given a loadOrgByKey dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger l'organisation (s). Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger l'organisation (s). Veuillez réessayer.")) } expect(consoleOutput).toEqual([ diff --git a/api/src/organization/loaders/__tests__/load-organization-by-slug.test.js b/api/src/organization/loaders/__tests__/load-organization-by-slug.test.js index b34b2c9daf..6ed5c7b824 100644 --- a/api/src/organization/loaders/__tests__/load-organization-by-slug.test.js +++ b/api/src/organization/loaders/__tests__/load-organization-by-slug.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' @@ -23,16 +24,16 @@ describe('given a loadOrgBySlug dataloader', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, - schema: dbschema, - })) + schema: dbschema, + })) }) beforeEach(async () => { await collections.organizations.save({ @@ -220,7 +221,7 @@ describe('given a loadOrgBySlug dataloader', () => { summaries: org.summaries, slugEN: org.orgDetails.en.slug, slugFR: org.orgDetails.fr.slug - }, + }, TRANSLATE("fr", org.orgDetails) ) ` @@ -251,7 +252,7 @@ describe('given a loadOrgBySlug dataloader', () => { summaries: org.summaries, slugEN: org.orgDetails.en.slug, slugFR: org.orgDetails.fr.slug - }, + }, TRANSLATE("fr", org.orgDetails) ) ` @@ -287,9 +288,7 @@ describe('given a loadOrgBySlug dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadOrgBySlug({ query: mockedQuery, language: 'en', @@ -300,9 +299,7 @@ describe('given a loadOrgBySlug dataloader', () => { try { await loader.load('slug') } catch (err) { - expect(err).toEqual( - new Error('Unable to load organization(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load organization(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -328,9 +325,7 @@ describe('given a loadOrgBySlug dataloader', () => { try { await loader.load('slug') } catch (err) { - expect(err).toEqual( - new Error('Unable to load organization(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load organization(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -356,9 +351,7 @@ describe('given a loadOrgBySlug dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadOrgBySlug({ query: mockedQuery, language: 'fr', @@ -369,11 +362,7 @@ describe('given a loadOrgBySlug dataloader', () => { try { await loader.load('slug') } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger l'organisation (s). Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger l'organisation (s). Veuillez réessayer.")) } expect(consoleOutput).toEqual([ @@ -399,11 +388,7 @@ describe('given a loadOrgBySlug dataloader', () => { try { await loader.load('slug') } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger l'organisation (s). Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger l'organisation (s). Veuillez réessayer.")) } expect(consoleOutput).toEqual([ diff --git a/api/src/organization/loaders/__tests__/load-organization-connections-by-domain-id.test.js b/api/src/organization/loaders/__tests__/load-organization-connections-by-domain-id.test.js index 7a930dfcaf..2d76724bb0 100644 --- a/api/src/organization/loaders/__tests__/load-organization-connections-by-domain-id.test.js +++ b/api/src/organization/loaders/__tests__/load-organization-connections-by-domain-id.test.js @@ -1,5 +1,6 @@ import { stringify } from 'jest-matcher-utils' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' @@ -12,17 +13,7 @@ import dbschema from '../../../../database.json' const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the load organizations connection function', () => { - let query, - drop, - truncate, - collections, - user, - org, - orgTwo, - domain, - domainTwo, - domainThree, - i18n + let query, drop, truncate, collections, user, org, orgTwo, domain, domainTwo, domainThree, i18n const consoleOutput = [] const mockedError = (output) => consoleOutput.push(output) @@ -38,16 +29,16 @@ describe('given the load organizations connection function', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, - - schema: dbschema, - })) + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, + + schema: dbschema, + })) }) beforeEach(async () => { user = await collections.users.save({ @@ -201,10 +192,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -251,10 +239,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -301,10 +286,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -350,10 +332,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -496,10 +475,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key]) const connectionArgs = { domainId: domain._id, @@ -2206,10 +2182,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -2262,10 +2235,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key]) const connectionArgs = { first: 5, @@ -2359,11 +2329,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - saOrg._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key, saOrg._key]) const connectionArgs = { first: 5, @@ -2419,11 +2385,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - saOrg._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key, saOrg._key]) const connectionArgs = { first: 5, @@ -2492,10 +2454,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -2542,10 +2501,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -2592,10 +2548,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -2641,10 +2594,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -2787,10 +2737,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key]) const connectionArgs = { domainId: domain._id, @@ -4497,10 +4444,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -4553,10 +4497,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key]) const connectionArgs = { first: 5, @@ -4650,11 +4591,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - saOrg._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key, saOrg._key]) const connectionArgs = { first: 5, @@ -4710,11 +4647,7 @@ describe('given the load organizations connection function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - org._key, - orgTwo._key, - saOrg._key, - ]) + const expectedOrgs = await orgLoader.loadMany([org._key, orgTwo._key, saOrg._key]) const connectionArgs = { first: 5, @@ -4857,11 +4790,7 @@ describe('given the load organizations connection function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` on the `Organization` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`first` on the `Organization` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ @@ -4889,11 +4818,7 @@ describe('given the load organizations connection function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` on the `Organization` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`last` on the `Organization` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ @@ -4971,9 +4896,7 @@ describe('given the load organizations connection function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadOrgConnectionsByDomainId({ query, language: 'en', @@ -4992,11 +4915,7 @@ describe('given the load organizations connection function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -5008,9 +4927,7 @@ describe('given the load organizations connection function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadOrgConnectionsByDomainId({ query, language: 'en', @@ -5029,11 +4946,7 @@ describe('given the load organizations connection function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: ${ @@ -5048,9 +4961,7 @@ describe('given the load organizations connection function', () => { describe('given a database error', () => { describe('when gathering organizations', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const query = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const connectionLoader = loadOrgConnectionsByDomainId({ query, @@ -5070,9 +4981,7 @@ describe('given the load organizations connection function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load organization(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load organization(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -5108,11 +5017,7 @@ describe('given the load organizations connection function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - 'Unable to load organization(s). Please try again.', - ), - ) + expect(err).toEqual(new Error('Unable to load organization(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -5224,9 +5129,7 @@ describe('given the load organizations connection function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`first` sur la connexion `Organization` ne peut être inférieure à zéro.', - ), + new Error('`first` sur la connexion `Organization` ne peut être inférieure à zéro.'), ) } @@ -5255,11 +5158,7 @@ describe('given the load organizations connection function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` sur la connexion `Organization` ne peut être inférieure à zéro.', - ), - ) + expect(err).toEqual(new Error('`last` sur la connexion `Organization` ne peut être inférieure à zéro.')) } expect(consoleOutput).toEqual([ @@ -5337,9 +5236,7 @@ describe('given the load organizations connection function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadOrgConnectionsByDomainId({ query, language: 'fr', @@ -5359,9 +5256,7 @@ describe('given the load organizations connection function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -5374,9 +5269,7 @@ describe('given the load organizations connection function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadOrgConnectionsByDomainId({ query, language: 'fr', @@ -5396,9 +5289,7 @@ describe('given the load organizations connection function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -5414,9 +5305,7 @@ describe('given the load organizations connection function', () => { describe('given a database error', () => { describe('when gathering organizations', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const query = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const connectionLoader = loadOrgConnectionsByDomainId({ query, @@ -5436,11 +5325,7 @@ describe('given the load organizations connection function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger l'organisation (s). Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger l'organisation (s). Veuillez réessayer.")) } expect(consoleOutput).toEqual([ @@ -5476,11 +5361,7 @@ describe('given the load organizations connection function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger l'organisation (s). Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger l'organisation (s). Veuillez réessayer.")) } expect(consoleOutput).toEqual([ diff --git a/api/src/organization/loaders/__tests__/load-organization-connections-by-user-id.test.js b/api/src/organization/loaders/__tests__/load-organization-connections-by-user-id.test.js index 8c8b2acbf1..dac18f6cdb 100644 --- a/api/src/organization/loaders/__tests__/load-organization-connections-by-user-id.test.js +++ b/api/src/organization/loaders/__tests__/load-organization-connections-by-user-id.test.js @@ -1,5 +1,6 @@ import { stringify } from 'jest-matcher-utils' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' @@ -12,17 +13,7 @@ import dbschema from '../../../../database.json' const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the load organization connections by user id function', () => { - let query, - drop, - truncate, - collections, - user, - orgOne, - orgTwo, - i18n, - domain, - domainTwo, - domainThree + let query, drop, truncate, collections, user, orgOne, orgTwo, i18n, domain, domainTwo, domainThree const consoleOutput = [] const mockedError = (output) => consoleOutput.push(output) @@ -39,16 +30,16 @@ describe('given the load organization connections by user id function', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, - - schema: dbschema, - })) + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, + + schema: dbschema, + })) }) beforeEach(async () => { user = await collections.users.save({ @@ -203,10 +194,7 @@ describe('given the load organization connections by user id function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -250,10 +238,7 @@ describe('given the load organization connections by user id function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -297,10 +282,7 @@ describe('given the load organization connections by user id function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -343,10 +325,7 @@ describe('given the load organization connections by user id function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -481,10 +460,7 @@ describe('given the load organization connections by user id function', () => { describe('search field is left empty', () => { it('returns unfiltered organizations', async () => { const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key]) const connectionLoader = loadOrgConnectionsByUserId({ query, @@ -522,10 +498,7 @@ describe('given the load organization connections by user id function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: false, - startCursor: toGlobalId( - 'organization', - expectedOrgs[0]._key, - ), + startCursor: toGlobalId('organization', expectedOrgs[0]._key), endCursor: toGlobalId('organization', expectedOrgs[1]._key), }, } @@ -2193,10 +2166,7 @@ describe('given the load organization connections by user id function', () => { const orgs = await connectionLoader({ ...connectionArgs }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -2240,10 +2210,7 @@ describe('given the load organization connections by user id function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key]) const connectionArgs = { first: 5, @@ -2330,11 +2297,7 @@ describe('given the load organization connections by user id function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - saOrg._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key, saOrg._key]) const connectionArgs = { first: 5, @@ -2367,10 +2330,7 @@ describe('given the load organization connections by user id function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: false, - startCursor: toGlobalId( - 'organization', - expectedOrgs[0]._key, - ), + startCursor: toGlobalId('organization', expectedOrgs[0]._key), endCursor: toGlobalId('organization', expectedOrgs[2]._key), }, } @@ -2390,11 +2350,7 @@ describe('given the load organization connections by user id function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'en' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - saOrg._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key, saOrg._key]) const connectionArgs = { first: 5, @@ -2421,10 +2377,7 @@ describe('given the load organization connections by user id function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: false, - startCursor: toGlobalId( - 'organization', - expectedOrgs[0]._key, - ), + startCursor: toGlobalId('organization', expectedOrgs[0]._key), endCursor: toGlobalId('organization', expectedOrgs[1]._key), }, } @@ -2497,10 +2450,7 @@ describe('given the load organization connections by user id function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -2544,10 +2494,7 @@ describe('given the load organization connections by user id function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -2591,10 +2538,7 @@ describe('given the load organization connections by user id function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -2637,10 +2581,7 @@ describe('given the load organization connections by user id function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -4366,10 +4307,7 @@ describe('given the load organization connections by user id function', () => { describe('search field is left empty', () => { it('returns unfiltered organizations', async () => { const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key]) const connectionLoader = loadOrgConnectionsByUserId({ query, @@ -4407,10 +4345,7 @@ describe('given the load organization connections by user id function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: false, - startCursor: toGlobalId( - 'organization', - expectedOrgs[0]._key, - ), + startCursor: toGlobalId('organization', expectedOrgs[0]._key), endCursor: toGlobalId('organization', expectedOrgs[1]._key), }, } @@ -4437,10 +4372,7 @@ describe('given the load organization connections by user id function', () => { const orgs = await connectionLoader({ ...connectionArgs }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key]) expectedOrgs[0].id = expectedOrgs[0]._key expectedOrgs[1].id = expectedOrgs[1]._key @@ -4484,10 +4416,7 @@ describe('given the load organization connections by user id function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key]) const connectionArgs = { first: 5, @@ -4574,11 +4503,7 @@ describe('given the load organization connections by user id function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - saOrg._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key, saOrg._key]) const connectionArgs = { first: 5, @@ -4611,10 +4536,7 @@ describe('given the load organization connections by user id function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: false, - startCursor: toGlobalId( - 'organization', - expectedOrgs[0]._key, - ), + startCursor: toGlobalId('organization', expectedOrgs[0]._key), endCursor: toGlobalId('organization', expectedOrgs[2]._key), }, } @@ -4634,11 +4556,7 @@ describe('given the load organization connections by user id function', () => { }) const orgLoader = loadOrgByKey({ query, language: 'fr' }) - const expectedOrgs = await orgLoader.loadMany([ - orgOne._key, - orgTwo._key, - saOrg._key, - ]) + const expectedOrgs = await orgLoader.loadMany([orgOne._key, orgTwo._key, saOrg._key]) const connectionArgs = { first: 5, @@ -4665,10 +4583,7 @@ describe('given the load organization connections by user id function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: false, - startCursor: toGlobalId( - 'organization', - expectedOrgs[0]._key, - ), + startCursor: toGlobalId('organization', expectedOrgs[0]._key), endCursor: toGlobalId('organization', expectedOrgs[1]._key), }, } @@ -4811,11 +4726,7 @@ describe('given the load organization connections by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` on the `Organization` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`first` on the `Organization` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ @@ -4842,11 +4753,7 @@ describe('given the load organization connections by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` on the `Organization` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`last` on the `Organization` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ @@ -4922,9 +4829,7 @@ describe('given the load organization connections by user id function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadOrgConnectionsByUserId({ query, userKey: 123, @@ -4943,11 +4848,7 @@ describe('given the load organization connections by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: 123 attempted to have \`first\` set as a ${typeof invalidInput} for: loadOrgConnectionsByUserId.`, @@ -4957,9 +4858,7 @@ describe('given the load organization connections by user id function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadOrgConnectionsByUserId({ query, userKey: 123, @@ -4978,11 +4877,7 @@ describe('given the load organization connections by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User: 123 attempted to have \`last\` set as a ${typeof invalidInput} for: loadOrgConnectionsByUserId.`, @@ -4995,11 +4890,7 @@ describe('given the load organization connections by user id function', () => { describe('given a database error', () => { describe('while querying domains', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue( - new Error('Unable to query organizations. Please try again.'), - ) + const query = jest.fn().mockRejectedValue(new Error('Unable to query organizations. Please try again.')) const connectionLoader = loadOrgConnectionsByUserId({ query, @@ -5018,9 +4909,7 @@ describe('given the load organization connections by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load organization(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load organization(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -5034,9 +4923,7 @@ describe('given the load organization connections by user id function', () => { it('returns an error message', async () => { const cursor = { next() { - throw new Error( - 'Unable to load organizations. Please try again.', - ) + throw new Error('Unable to load organizations. Please try again.') }, } const query = jest.fn().mockReturnValueOnce(cursor) @@ -5058,9 +4945,7 @@ describe('given the load organization connections by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load organization(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load organization(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -5168,9 +5053,7 @@ describe('given the load organization connections by user id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`first` sur la connexion `Organization` ne peut être inférieure à zéro.', - ), + new Error('`first` sur la connexion `Organization` ne peut être inférieure à zéro.'), ) } @@ -5198,11 +5081,7 @@ describe('given the load organization connections by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` sur la connexion `Organization` ne peut être inférieure à zéro.', - ), - ) + expect(err).toEqual(new Error('`last` sur la connexion `Organization` ne peut être inférieure à zéro.')) } expect(consoleOutput).toEqual([ @@ -5278,9 +5157,7 @@ describe('given the load organization connections by user id function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadOrgConnectionsByUserId({ query, userKey: 123, @@ -5300,9 +5177,7 @@ describe('given the load organization connections by user id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -5313,9 +5188,7 @@ describe('given the load organization connections by user id function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadOrgConnectionsByUserId({ query, userKey: 123, @@ -5335,9 +5208,7 @@ describe('given the load organization connections by user id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -5351,11 +5222,7 @@ describe('given the load organization connections by user id function', () => { describe('given a database error', () => { describe('while querying domains', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue( - new Error('Unable to query organizations. Please try again.'), - ) + const query = jest.fn().mockRejectedValue(new Error('Unable to query organizations. Please try again.')) const connectionLoader = loadOrgConnectionsByUserId({ query, @@ -5374,11 +5241,7 @@ describe('given the load organization connections by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger l'organisation (s). Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger l'organisation (s). Veuillez réessayer.")) } expect(consoleOutput).toEqual([ @@ -5392,9 +5255,7 @@ describe('given the load organization connections by user id function', () => { it('returns an error message', async () => { const cursor = { next() { - throw new Error( - 'Unable to load organizations. Please try again.', - ) + throw new Error('Unable to load organizations. Please try again.') }, } const query = jest.fn().mockReturnValueOnce(cursor) @@ -5416,11 +5277,7 @@ describe('given the load organization connections by user id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - "Impossible de charger l'organisation (s). Veuillez réessayer.", - ), - ) + expect(err).toEqual(new Error("Impossible de charger l'organisation (s). Veuillez réessayer.")) } expect(consoleOutput).toEqual([ diff --git a/api/src/organization/loaders/load-all-organization-domain-statuses.js b/api/src/organization/loaders/load-all-organization-domain-statuses.js index 02e0efad5f..e1f561fad3 100644 --- a/api/src/organization/loaders/load-all-organization-domain-statuses.js +++ b/api/src/organization/loaders/load-all-organization-domain-statuses.js @@ -74,6 +74,16 @@ export const loadAllOrganizationDomainStatuses = ${domainFilters} FILTER d.wildcardSibling ${comparison} true ` + } else if (filterValue === 'has-entrust-certificate') { + domainFilters = aql` + ${domainFilters} + FILTER d.hasEntrustCertificate ${comparison} true + ` + } else if (filterValue === 'cve-detected') { + domainFilters = aql` + ${domainFilters} + FILTER d.cveDetected ${comparison} true + ` } } }) @@ -85,8 +95,16 @@ export const loadAllOrganizationDomainStatuses = WITH domains FOR d IN domains ${domainFilters} + LET ipAddresses = ( + FOR web, webE IN 1 OUTBOUND d._id domainsWeb + SORT web.timestamp DESC + LIMIT 1 + FOR webScan, webScanE IN 1 OUTBOUND web._id webToWebScans + RETURN webScan.ipAddress + ) RETURN { "domain": d.domain, + "ipAddresses": ipAddresses, "https": d.status.https, "hsts": d.status.hsts, "certificates": d.status.certificates, @@ -98,7 +116,9 @@ export const loadAllOrganizationDomainStatuses = "dmarc": d.status.dmarc, "rcode": d.rcode, "blocked": d.blocked, - "wildcardSibling": d.wildcardSibling + "wildcardSibling": d.wildcardSibling, + "hasEntrustCertificate": d.hasEntrustCertificate, + "hasTop25Vulnerability": d.cveDetected } ` ).all() diff --git a/api/src/organization/loaders/load-organization-connections-by-domain-id.js b/api/src/organization/loaders/load-organization-connections-by-domain-id.js index f7e572944b..c36130ea38 100644 --- a/api/src/organization/loaders/load-organization-connections-by-domain-id.js +++ b/api/src/organization/loaders/load-organization-connections-by-domain-id.js @@ -402,29 +402,37 @@ export const loadOrgConnectionsByDomainId = search = cleanseInput(search) orgQuery = aql` LET tokenArrEN = TOKENS(${search}, "text_en") - LET searchedOrgsEN = FLATTEN(UNIQUE( + LET searchedOrgsKeysCountEN = FLATTEN( FOR token IN tokenArrEN FOR org IN organizationSearch SEARCH ANALYZER( - org.orgDetails.en.acronym LIKE CONCAT("%", token, "%") - OR org.orgDetails.fr.acronym LIKE CONCAT("%", token, "%") - OR org.orgDetails.en.name LIKE CONCAT("%", token, "%") - OR org.orgDetails.fr.name LIKE CONCAT("%", token, "%") + org.orgDetails.en.acronym LIKE CONCAT("%", token, "%") + OR org.orgDetails.en.name LIKE CONCAT("%", token, "%") , "text_en") FILTER org._key IN orgKeys - RETURN org._key - )) + COLLECT orgKey = org._key WITH COUNT INTO orgCount + RETURN { + 'orgKey': orgKey, + 'orgCount': orgCount + } + ) + LET searchedOrgsEN = searchedOrgsKeysCountEN[* FILTER CURRENT.orgCount == LENGTH(tokenArrEN)].orgKey LET tokenArrFR = TOKENS(${search}, "text_fr") - LET searchedOrgsFR = FLATTEN(UNIQUE( + LET searchedOrgsKeysCountFR = FLATTEN( FOR token IN tokenArrFR - FOR org IN organizationSearch - SEARCH ANALYZER( + FOR org IN organizationSearch + SEARCH ANALYZER( org.orgDetails.fr.acronym LIKE CONCAT("%", token, "%") OR org.orgDetails.fr.name LIKE CONCAT("%", token, "%") - , "text_fr") - FILTER org._key IN orgKeys - RETURN org._key - )) + , "text_fr") + FILTER org._key IN orgKeys + COLLECT orgKey = org._key WITH COUNT INTO orgCount + RETURN { + 'orgKey': orgKey, + 'orgCount': orgCount + } + ) + LET searchedOrgsFR = searchedOrgsKeysCountFR[* FILTER CURRENT.orgCount == LENGTH(tokenArrFR)].orgKey LET searchedOrgs = UNION_DISTINCT(searchedOrgsEN, searchedOrgsFR) ` filterString = aql`FILTER org._key IN searchedOrgs` diff --git a/api/src/organization/loaders/load-organization-connections-by-user-id.js b/api/src/organization/loaders/load-organization-connections-by-user-id.js index 7dcbd27411..9c0e9ee30a 100644 --- a/api/src/organization/loaders/load-organization-connections-by-user-id.js +++ b/api/src/organization/loaders/load-organization-connections-by-user-id.js @@ -438,7 +438,7 @@ export const loadOrgConnectionsByUserId = search = cleanseInput(search) orgQuery = aql` LET tokenArrEN = TOKENS(${search}, "text_en") - LET searchedOrgsEN = FLATTEN(UNIQUE( + LET searchedOrgsKeysCountEN = FLATTEN( FOR token IN tokenArrEN FOR org IN organizationSearch SEARCH ANALYZER( @@ -446,10 +446,15 @@ export const loadOrgConnectionsByUserId = OR org.orgDetails.en.name LIKE CONCAT("%", token, "%") , "text_en") FILTER org._key IN orgKeys - RETURN org._key - )) + COLLECT orgKey = org._key WITH COUNT INTO orgCount + RETURN { + 'orgKey': orgKey, + 'orgCount': orgCount + } + ) + LET searchedOrgsEN = searchedOrgsKeysCountEN[* FILTER CURRENT.orgCount == LENGTH(tokenArrEN)].orgKey LET tokenArrFR = TOKENS(${search}, "text_fr") - LET searchedOrgsFR = FLATTEN(UNIQUE( + LET searchedOrgsKeysCountFR = FLATTEN( FOR token IN tokenArrFR FOR org IN organizationSearch SEARCH ANALYZER( @@ -457,8 +462,13 @@ export const loadOrgConnectionsByUserId = OR org.orgDetails.fr.name LIKE CONCAT("%", token, "%") , "text_fr") FILTER org._key IN orgKeys - RETURN org._key - )) + COLLECT orgKey = org._key WITH COUNT INTO orgCount + RETURN { + 'orgKey': orgKey, + 'orgCount': orgCount + } + ) + LET searchedOrgsFR = searchedOrgsKeysCountFR[* FILTER CURRENT.orgCount == LENGTH(tokenArrFR)].orgKey LET searchedOrgs = UNION_DISTINCT(searchedOrgsEN, searchedOrgsFR) ` filterString = aql`FILTER org._key IN searchedOrgs` diff --git a/api/src/organization/loaders/load-organization-domain-statuses.js b/api/src/organization/loaders/load-organization-domain-statuses.js index 65b289575c..5a246a13e9 100644 --- a/api/src/organization/loaders/load-organization-domain-statuses.js +++ b/api/src/organization/loaders/load-organization-domain-statuses.js @@ -59,12 +59,7 @@ export const loadOrganizationDomainStatuses = FILTER v.status.certificates ${comparison} ${filterValue} ` } else if (filterCategory === 'tags') { - if (filterValue === 'hidden') { - domainFilters = aql` - ${domainFilters} - FILTER e.hidden ${comparison} true - ` - } else if (filterValue === 'nxdomain') { + if (filterValue === 'nxdomain') { domainFilters = aql` ${domainFilters} FILTER v.rcode ${comparison} "NXDOMAIN" @@ -79,12 +74,27 @@ export const loadOrganizationDomainStatuses = ${domainFilters} FILTER v.wildcardSibling ${comparison} true ` + } else if (filterValue === 'has-entrust-certificate') { + domainFilters = aql` + ${domainFilters} + FILTER v.hasEntrustCertificate ${comparison} true + ` + } else if (filterValue === 'cve-detected') { + domainFilters = aql` + ${domainFilters} + FILTER v.cveDetected ${comparison} true + ` } else { domainFilters = aql` ${domainFilters} FILTER POSITION(claimTags, ${filterValue}) ${comparison} true ` } + } else if (filterCategory === 'asset-state') { + domainFilters = aql` + ${domainFilters} + FILTER e.assetState ${comparison} ${filterValue} + ` } }) } @@ -102,14 +112,24 @@ export const loadOrganizationDomainStatuses = RETURN translatedTags )[0] ${domainFilters} + LET ipAddresses = ( + FOR web, webE IN 1 OUTBOUND v._id domainsWeb + SORT web.timestamp DESC + LIMIT 1 + FOR webScan, webScanE IN 1 OUTBOUND web._id webToWebScans + RETURN webScan.ipAddress + ) RETURN { domain: v.domain, + ipAddresses: ipAddresses, status: v.status, tags: claimTags, - hidden: e.hidden, + assetState: e.assetState, rcode: v.rcode, blocked: v.blocked, wildcardSibling: v.wildcardSibling, + hasEntrustCertificate: v.hasEntrustCertificate, + cveDetected: v.cveDetected } ` ).all() diff --git a/api/src/organization/mutations/__tests__/archive-organization.test.js b/api/src/organization/mutations/__tests__/archive-organization.test.js index c45c4fd0d8..9a34d82c8b 100644 --- a/api/src/organization/mutations/__tests__/archive-organization.test.js +++ b/api/src/organization/mutations/__tests__/archive-organization.test.js @@ -1,5 +1,6 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/organization/mutations/__tests__/create-organization.test.js b/api/src/organization/mutations/__tests__/create-organization.test.js index 38cb6b57a3..5b71086fab 100644 --- a/api/src/organization/mutations/__tests__/create-organization.test.js +++ b/api/src/organization/mutations/__tests__/create-organization.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/organization/mutations/__tests__/remove-organization.test.js b/api/src/organization/mutations/__tests__/remove-organization.test.js index b349b89d09..812e7b5670 100644 --- a/api/src/organization/mutations/__tests__/remove-organization.test.js +++ b/api/src/organization/mutations/__tests__/remove-organization.test.js @@ -1,5 +1,6 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/organization/mutations/__tests__/update-organization.test.js b/api/src/organization/mutations/__tests__/update-organization.test.js index 4615f2252c..cc99858e80 100644 --- a/api/src/organization/mutations/__tests__/update-organization.test.js +++ b/api/src/organization/mutations/__tests__/update-organization.test.js @@ -1,5 +1,6 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/organization/mutations/__tests__/verify-organization.test.js b/api/src/organization/mutations/__tests__/verify-organization.test.js index 96b8c8908c..e6a2ec67aa 100644 --- a/api/src/organization/mutations/__tests__/verify-organization.test.js +++ b/api/src/organization/mutations/__tests__/verify-organization.test.js @@ -1,5 +1,6 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/organization/objects/organization.js b/api/src/organization/objects/organization.js index dbfa513b1e..c1dcc50a6e 100644 --- a/api/src/organization/objects/organization.js +++ b/api/src/organization/objects/organization.js @@ -159,6 +159,7 @@ export const organizationType = new GraphQLObjectType({ }) const headers = [ 'domain', + 'ipAddresses', 'https', 'hsts', 'certificates', @@ -169,22 +170,38 @@ export const organizationType = new GraphQLObjectType({ 'dkim', 'dmarc', 'tags', - 'hidden', + 'assetState', 'rcode', 'blocked', 'wildcardSibling', + 'hasEntrustCertificate', + 'top25VulnerabilityDetected', ] let csvOutput = headers.join(',') - domains.forEach((domain) => { - let csvLine = `${domain.domain}` - csvLine += headers.slice(1, 10).reduce((previousValue, currentHeader) => { - return `${previousValue},${domain.status[currentHeader]}` - }, '') - csvLine += `,${domain.tags.join('|')},${domain.hidden},${domain.rcode},${domain.blocked},${ - domain.wildcardSibling - }` - csvOutput += `\n${csvLine}` - }) + domains.forEach( + ({ + domain, + ipAddresses, + status, + tags, + assetState, + rcode, + blocked, + wildcardSibling, + hasEntrustCertificate, + cveDetected, + }) => { + let csvLine = `${domain}` + csvLine += `,${ipAddresses.join('|')}` + csvLine += headers.slice(2, 11).reduce((previousValue, currentHeader) => { + return `${previousValue},${status[currentHeader]}` + }, '') + csvLine += `,${tags.join( + '|', + )},${assetState},${rcode},${blocked},${wildcardSibling},${hasEntrustCertificate},${cveDetected}` + csvOutput += `\n${csvLine}` + }, + ) // Get org names to use in activity log let orgNamesCursor diff --git a/api/src/organization/queries/__tests__/find-my-organizations.test.js b/api/src/organization/queries/__tests__/find-my-organizations.test.js index 3978797596..e17d21ad71 100644 --- a/api/src/organization/queries/__tests__/find-my-organizations.test.js +++ b/api/src/organization/queries/__tests__/find-my-organizations.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/organization/queries/__tests__/find-organization-by-slug.test.js b/api/src/organization/queries/__tests__/find-organization-by-slug.test.js index d91d62cb25..8a99ceb76c 100644 --- a/api/src/organization/queries/__tests__/find-organization-by-slug.test.js +++ b/api/src/organization/queries/__tests__/find-organization-by-slug.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/organization/queries/__tests__/get-all-organization-domain-statuses.test.js b/api/src/organization/queries/__tests__/get-all-organization-domain-statuses.test.js index 3c99559d7b..90fea9bd67 100644 --- a/api/src/organization/queries/__tests__/get-all-organization-domain-statuses.test.js +++ b/api/src/organization/queries/__tests__/get-all-organization-domain-statuses.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { createQuerySchema } from '../../../query' @@ -110,6 +111,8 @@ describe('given getAllOrganizationDomainStatuses', () => { rcode: 'NOERROR', blocked: false, wildcardSibling: false, + hasEntrustCertificate: false, + cveDetected: false, }) domainTwo = await collections.domains.save({ domain: 'domain.two', @@ -127,6 +130,8 @@ describe('given getAllOrganizationDomainStatuses', () => { rcode: 'NOERROR', blocked: false, wildcardSibling: false, + hasEntrustCertificate: false, + cveDetected: false, }) }) afterEach(async () => { @@ -242,9 +247,9 @@ describe('given getAllOrganizationDomainStatuses', () => { const expectedResponse = { data: { - getAllOrganizationDomainStatuses: `domain,https,hsts,certificates,ciphers,curves,protocols,spf,dkim,dmarc,rcode,blocked,wildcardSibling -"domain.one","fail","pass","pass","pass","pass","pass","pass","pass","pass","NOERROR","false","false" -"domain.two","pass","fail","pass","fail","pass","fail","pass","pass","fail","NOERROR","false","false"`, + getAllOrganizationDomainStatuses: `domain,ipAddresses,https,hsts,certificates,ciphers,curves,protocols,spf,dkim,dmarc,rcode,blocked,wildcardSibling,hasEntrustCertificate,hasTop25Vulnerability +"domain.one",,"fail","pass","pass","pass","pass","pass","pass","pass","pass","NOERROR","false","false","false","false" +"domain.two",,"pass","fail","pass","fail","pass","fail","pass","pass","fail","NOERROR","false","false","false","false"`, }, } @@ -359,9 +364,9 @@ describe('given getAllOrganizationDomainStatuses', () => { }) const expectedResponse = { data: { - getAllOrganizationDomainStatuses: `domain,https,hsts,certificates,ciphers,curves,protocols,spf,dkim,dmarc,rcode,blocked,wildcardSibling -"domain.one","fail","pass","pass","pass","pass","pass","pass","pass","pass","NOERROR","false","false" -"domain.two","pass","fail","pass","fail","pass","fail","pass","pass","fail","NOERROR","false","false"`, + getAllOrganizationDomainStatuses: `domain,ipAddresses,https,hsts,certificates,ciphers,curves,protocols,spf,dkim,dmarc,rcode,blocked,wildcardSibling,hasEntrustCertificate,hasTop25Vulnerability +"domain.one",,"fail","pass","pass","pass","pass","pass","pass","pass","pass","NOERROR","false","false","false","false" +"domain.two",,"pass","fail","pass","fail","pass","fail","pass","pass","fail","NOERROR","false","false","false","false"`, }, } expect(response).toEqual(expectedResponse) diff --git a/api/src/organization/queries/get-all-organization-domain-statuses.js b/api/src/organization/queries/get-all-organization-domain-statuses.js index 59ceba5ee3..75bb6f7424 100644 --- a/api/src/organization/queries/get-all-organization-domain-statuses.js +++ b/api/src/organization/queries/get-all-organization-domain-statuses.js @@ -33,6 +33,7 @@ export const getAllOrganizationDomainStatuses = { const headers = [ 'domain', + 'ipAddresses', 'https', 'hsts', 'certificates', @@ -45,10 +46,19 @@ export const getAllOrganizationDomainStatuses = { 'rcode', 'blocked', 'wildcardSibling', + 'hasEntrustCertificate', + 'hasTop25Vulnerability', ] let csvOutput = headers.join(',') domainStatuses.forEach((domainStatus) => { - const csvLine = headers.map((header) => `"${domainStatus[header]}"`).join(',') + const csvLine = headers + .map((header) => { + if (header === 'ipAddresses') { + return domainStatus[header].join('|') + } + return `"${domainStatus[header]}"` + }) + .join(',') csvOutput += `\n${csvLine}` }) diff --git a/api/src/summaries/loaders/__tests__/load-chart-summary-by-key.test.js b/api/src/summaries/loaders/__tests__/load-chart-summary-by-key.test.js index 8e873a9195..ac697bd07b 100644 --- a/api/src/summaries/loaders/__tests__/load-chart-summary-by-key.test.js +++ b/api/src/summaries/loaders/__tests__/load-chart-summary-by-key.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' diff --git a/api/src/summaries/queries/__tests__/dkim-summary.test.js b/api/src/summaries/queries/__tests__/dkim-summary.test.js index a5aa0f7e8f..75481e8f91 100644 --- a/api/src/summaries/queries/__tests__/dkim-summary.test.js +++ b/api/src/summaries/queries/__tests__/dkim-summary.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/summaries/queries/__tests__/dmarc-phase-summary.test.js b/api/src/summaries/queries/__tests__/dmarc-phase-summary.test.js index 49202b9000..fc3cf563ac 100644 --- a/api/src/summaries/queries/__tests__/dmarc-phase-summary.test.js +++ b/api/src/summaries/queries/__tests__/dmarc-phase-summary.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/summaries/queries/__tests__/dmarc-summary.test.js b/api/src/summaries/queries/__tests__/dmarc-summary.test.js index 8451287d8c..1a100dad14 100644 --- a/api/src/summaries/queries/__tests__/dmarc-summary.test.js +++ b/api/src/summaries/queries/__tests__/dmarc-summary.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/summaries/queries/__tests__/find-chart-summaries.test.js b/api/src/summaries/queries/__tests__/find-chart-summaries.test.js index 8805dcb8c5..13ab94495a 100644 --- a/api/src/summaries/queries/__tests__/find-chart-summaries.test.js +++ b/api/src/summaries/queries/__tests__/find-chart-summaries.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/summaries/queries/__tests__/https-summary.test.js b/api/src/summaries/queries/__tests__/https-summary.test.js index 8870b362a4..47d3d3919d 100644 --- a/api/src/summaries/queries/__tests__/https-summary.test.js +++ b/api/src/summaries/queries/__tests__/https-summary.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/summaries/queries/__tests__/mail-summary.test.js b/api/src/summaries/queries/__tests__/mail-summary.test.js index 713583132e..1711ca2de5 100644 --- a/api/src/summaries/queries/__tests__/mail-summary.test.js +++ b/api/src/summaries/queries/__tests__/mail-summary.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/summaries/queries/__tests__/spf-summary.test.js b/api/src/summaries/queries/__tests__/spf-summary.test.js index 393ed8cf6d..095b282fb8 100644 --- a/api/src/summaries/queries/__tests__/spf-summary.test.js +++ b/api/src/summaries/queries/__tests__/spf-summary.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/summaries/queries/__tests__/ssl-summary.test.js b/api/src/summaries/queries/__tests__/ssl-summary.test.js index 38d3c70d9d..c3a813a039 100644 --- a/api/src/summaries/queries/__tests__/ssl-summary.test.js +++ b/api/src/summaries/queries/__tests__/ssl-summary.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/summaries/queries/__tests__/web-connections-summary.test.js b/api/src/summaries/queries/__tests__/web-connections-summary.test.js index 9bcd2c92f7..afd2dd17c7 100644 --- a/api/src/summaries/queries/__tests__/web-connections-summary.test.js +++ b/api/src/summaries/queries/__tests__/web-connections-summary.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/summaries/queries/__tests__/web-summary.test.js b/api/src/summaries/queries/__tests__/web-summary.test.js index d3045051fb..4b1a8dc3bb 100644 --- a/api/src/summaries/queries/__tests__/web-summary.test.js +++ b/api/src/summaries/queries/__tests__/web-summary.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/testUtilities.js b/api/src/testUtilities.js new file mode 100644 index 0000000000..ccd00dacdb --- /dev/null +++ b/api/src/testUtilities.js @@ -0,0 +1,35 @@ +import { ensure } from 'arango-tools' +import { Database } from 'arangojs' + +export async function ensureDatabase(options) { + let variables + if (options.variables) { + variables = options.variables + variables.name = variables.dbname + } else { + variables = { ...options } + } + const systemDatabase = new Database({ url: variables.url, databaseName: '_system' }) + await systemDatabase.login('root', variables.rootPassword) + const databases = await systemDatabase.listDatabases() + if (!databases.includes(variables.name)) { + try { + await systemDatabase.createDatabase(variables.name) + } catch (e) { + console.error(`Failed to create database ${variables.name}: ${e.message}`) + process.exit(1) + } + } + + let ensureOptions + if (options.variables) { + ensureOptions = { + variables: options.variables, + schema: { ...options.schema }, + } + } else { + ensureOptions = options + } + + return await ensure(ensureOptions) +} diff --git a/api/src/user/loaders/__tests__/load-user-by-key.test.js b/api/src/user/loaders/__tests__/load-user-by-key.test.js index 5a91f7aa5b..cfabe166f6 100644 --- a/api/src/user/loaders/__tests__/load-user-by-key.test.js +++ b/api/src/user/loaders/__tests__/load-user-by-key.test.js @@ -1,12 +1,13 @@ -import {ensure, dbNameFromFile} from 'arango-tools' -import {setupI18n} from '@lingui/core' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' +import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' import frenchMessages from '../../../locale/fr/messages' -import {loadUserByKey} from '../index' +import { loadUserByKey } from '../index' import dbschema from '../../../../database.json' -const {DB_PASS: rootPass, DB_URL: url} = process.env +const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given a loadUserByKey dataloader', () => { let query, drop, truncate, collections, i18n @@ -18,8 +19,8 @@ describe('given a loadUserByKey dataloader', () => { i18n = setupI18n({ locale: 'en', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -34,7 +35,7 @@ describe('given a loadUserByKey dataloader', () => { describe('given a successful load', () => { beforeAll(async () => { - ;({query, drop, truncate, collections} = await ensure({ + ;({ query, drop, truncate, collections } = await ensure({ variables: { dbname: dbNameFromFile(__filename), username: 'root', @@ -78,7 +79,7 @@ describe('given a loadUserByKey dataloader', () => { ` const expectedUser = await expectedCursor.next() - const loader = loadUserByKey({query}) + const loader = loadUserByKey({ query }) const user = await loader.load(expectedUser._key) expect(user).toEqual(expectedUser) @@ -99,7 +100,7 @@ describe('given a loadUserByKey dataloader', () => { expectedUsers.push(tempUser) } - const loader = loadUserByKey({query}) + const loader = loadUserByKey({ query }) const users = await loader.loadMany(userKeys) expect(users).toEqual(expectedUsers) }) @@ -111,8 +112,8 @@ describe('given a loadUserByKey dataloader', () => { i18n = setupI18n({ locale: 'en', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -123,9 +124,7 @@ describe('given a loadUserByKey dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadUserByKey({ query: mockedQuery, userKey: '1234', @@ -135,9 +134,7 @@ describe('given a loadUserByKey dataloader', () => { try { await loader.load('1234') } catch (err) { - expect(err).toEqual( - new Error('Unable to load user(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load user(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -162,9 +159,7 @@ describe('given a loadUserByKey dataloader', () => { try { await loader.load('1234') } catch (err) { - expect(err).toEqual( - new Error('Unable to load user(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load user(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -178,8 +173,8 @@ describe('given a loadUserByKey dataloader', () => { i18n = setupI18n({ locale: 'fr', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -190,9 +185,7 @@ describe('given a loadUserByKey dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadUserByKey({ query: mockedQuery, userKey: '1234', @@ -202,11 +195,7 @@ describe('given a loadUserByKey dataloader', () => { try { await loader.load('1234') } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) utilisateur(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) utilisateur(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ @@ -231,11 +220,7 @@ describe('given a loadUserByKey dataloader', () => { try { await loader.load('1234') } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) utilisateur(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) utilisateur(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ diff --git a/api/src/user/loaders/__tests__/load-user-by-username.test.js b/api/src/user/loaders/__tests__/load-user-by-username.test.js index 6dd21b4f1e..c8825c1426 100644 --- a/api/src/user/loaders/__tests__/load-user-by-username.test.js +++ b/api/src/user/loaders/__tests__/load-user-by-username.test.js @@ -1,12 +1,13 @@ -import {ensure, dbNameFromFile} from 'arango-tools' -import {setupI18n} from '@lingui/core' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' +import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' import frenchMessages from '../../../locale/fr/messages' -import {loadUserByUserName} from '../index' +import { loadUserByUserName } from '../index' import dbschema from '../../../../database.json' -const {DB_PASS: rootPass, DB_URL: url} = process.env +const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given a loadUserByUserName dataloader', () => { let query, drop, truncate, collections, i18n @@ -17,8 +18,8 @@ describe('given a loadUserByUserName dataloader', () => { i18n = setupI18n({ locale: 'en', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -33,7 +34,7 @@ describe('given a loadUserByUserName dataloader', () => { describe('given a successful load', () => { beforeAll(async () => { - ;({query, drop, truncate, collections} = await ensure({ + ;({ query, drop, truncate, collections } = await ensure({ variables: { dbname: dbNameFromFile(__filename), username: 'root', @@ -70,7 +71,7 @@ describe('given a loadUserByUserName dataloader', () => { describe('provided a single username', () => { it('returns a single user', async () => { const userName = 'random@email.ca' - const loader = loadUserByUserName({query, i18n}) + const loader = loadUserByUserName({ query, i18n }) // Get Query User const cursor = await query` @@ -87,11 +88,8 @@ describe('given a loadUserByUserName dataloader', () => { describe('provided a list of usernames', () => { it('returns a list of users', async () => { const expectedUsers = [] - const userNames = [ - 'random@email.ca', - 'test.account@istio.actually.exists', - ] - const loader = loadUserByUserName({query, i18n}) + const userNames = ['random@email.ca', 'test.account@istio.actually.exists'] + const loader = loadUserByUserName({ query, i18n }) for (const i in userNames) { // Get Query User @@ -114,8 +112,8 @@ describe('given a loadUserByUserName dataloader', () => { i18n = setupI18n({ locale: 'en', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -128,17 +126,13 @@ describe('given a loadUserByUserName dataloader', () => { it('throws an error', async () => { const userName = 'random@email.ca' - query = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) - const loader = loadUserByUserName({query, userKey: '1234', i18n}) + query = jest.fn().mockRejectedValue(new Error('Database error occurred.')) + const loader = loadUserByUserName({ query, userKey: '1234', i18n }) try { await loader.load(userName) } catch (err) { - expect(err).toEqual( - new Error('Unable to load user(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load user(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -156,14 +150,12 @@ describe('given a loadUserByUserName dataloader', () => { }, } query = jest.fn().mockReturnValue(cursor) - const loader = loadUserByUserName({query, userKey: '1234', i18n}) + const loader = loadUserByUserName({ query, userKey: '1234', i18n }) try { await loader.load(userName) } catch (err) { - expect(err).toEqual( - new Error('Unable to load user(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load user(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -177,8 +169,8 @@ describe('given a loadUserByUserName dataloader', () => { i18n = setupI18n({ locale: 'fr', localeData: { - en: {plurals: {}}, - fr: {plurals: {}}, + en: { plurals: {} }, + fr: { plurals: {} }, }, locales: ['en', 'fr'], messages: { @@ -191,19 +183,13 @@ describe('given a loadUserByUserName dataloader', () => { it('throws an error', async () => { const userName = 'random@email.ca' - query = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) - const loader = loadUserByUserName({query, userKey: '1234', i18n}) + query = jest.fn().mockRejectedValue(new Error('Database error occurred.')) + const loader = loadUserByUserName({ query, userKey: '1234', i18n }) try { await loader.load(userName) } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) utilisateur(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) utilisateur(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ @@ -221,16 +207,12 @@ describe('given a loadUserByUserName dataloader', () => { }, } query = jest.fn().mockReturnValue(cursor) - const loader = loadUserByUserName({query, userKey: '1234', i18n}) + const loader = loadUserByUserName({ query, userKey: '1234', i18n }) try { await loader.load(userName) } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) utilisateur(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) utilisateur(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ diff --git a/api/src/user/loaders/load-user-connections-by-user-id.js b/api/src/user/loaders/load-user-connections-by-user-id.js index 4d0aeeb6e9..14d0a10755 100644 --- a/api/src/user/loaders/load-user-connections-by-user-id.js +++ b/api/src/user/loaders/load-user-connections-by-user-id.js @@ -1,245 +1,235 @@ -import {aql} from 'arangojs' -import {fromGlobalId, toGlobalId} from 'graphql-relay' -import {t} from '@lingui/macro' +import { aql } from 'arangojs' +import { fromGlobalId, toGlobalId } from 'graphql-relay' +import { t } from '@lingui/macro' export const loadUserConnectionsByUserId = - ({query, userKey, cleanseInput, i18n}) => - async ({after, before, first, last, orderBy, isSuperAdmin, search}) => { - const userDBId = `users/${userKey}` + ({ query, userKey, cleanseInput, i18n }) => + async ({ after, before, first, last, orderBy, isSuperAdmin, search }) => { + const userDBId = `users/${userKey}` - let afterTemplate = aql`` - let afterVar = aql`` + let afterTemplate = aql`` + let afterVar = aql`` - if (typeof after !== 'undefined') { - const {id: afterId} = fromGlobalId(cleanseInput(after)) - if (typeof orderBy === 'undefined') { - afterTemplate = aql`FILTER TO_NUMBER(user._key) > TO_NUMBER(${afterId})` + if (typeof after !== 'undefined') { + const { id: afterId } = fromGlobalId(cleanseInput(after)) + if (typeof orderBy === 'undefined') { + afterTemplate = aql`FILTER TO_NUMBER(user._key) > TO_NUMBER(${afterId})` + } else { + let afterTemplateDirection = aql`` + if (orderBy.direction === 'ASC') { + afterTemplateDirection = aql`>` } else { - let afterTemplateDirection = aql`` - if (orderBy.direction === 'ASC') { - afterTemplateDirection = aql`>` - } else { - afterTemplateDirection = aql`<` - } + afterTemplateDirection = aql`<` + } - afterVar = aql`LET afterVar = DOCUMENT(users, ${afterId})` + afterVar = aql`LET afterVar = DOCUMENT(users, ${afterId})` - let documentField = aql`` - let userField = aql`` - /* istanbul ignore else */ - if (orderBy.field === 'user-username') { - documentField = aql`afterVar.userName` - userField = aql`user.userName` - } else if (orderBy.field === 'user-displayName') { - documentField = aql`afterVar.displayName` - userField = aql`user.displayName` - } else if (orderBy.field === 'user-emailValidated') { - documentField = aql`afterVar.emailValidated` - userField = aql`user.emailValidated` - } else if (orderBy.field === 'user-affiliations-totalCount') { - documentField = aql`afterVar.affiliations.totalCount` - userField = aql`user.affiliations.totalCount` - } else if (orderBy.field === 'user-insider') { + let documentField = aql`` + let userField = aql`` + /* istanbul ignore else */ + if (orderBy.field === 'user-username') { + documentField = aql`afterVar.userName` + userField = aql`user.userName` + } else if (orderBy.field === 'user-displayName') { + documentField = aql`afterVar.displayName` + userField = aql`user.displayName` + } else if (orderBy.field === 'user-emailValidated') { + documentField = aql`afterVar.emailValidated` + userField = aql`user.emailValidated` + } else if (orderBy.field === 'user-affiliations-totalCount') { + documentField = aql`afterVar.affiliations.totalCount` + userField = aql`user.affiliations.totalCount` + } else if (orderBy.field === 'user-insider') { documentField = aql`afterVar.insiderUser` userField = aql`user.insiderUser` } - afterTemplate = aql` + afterTemplate = aql` FILTER ${userField} ${afterTemplateDirection} ${documentField} OR (${userField} == ${documentField} AND TO_NUMBER(user._key) > TO_NUMBER(${afterId})) ` - } } + } - let beforeTemplate = aql`` - let beforeVar = aql`` + let beforeTemplate = aql`` + let beforeVar = aql`` - if (typeof before !== 'undefined') { - const {id: beforeId} = fromGlobalId(cleanseInput(before)) - if (typeof orderBy === 'undefined') { - beforeTemplate = aql`FILTER TO_NUMBER(user._key) < TO_NUMBER(${beforeId})` + if (typeof before !== 'undefined') { + const { id: beforeId } = fromGlobalId(cleanseInput(before)) + if (typeof orderBy === 'undefined') { + beforeTemplate = aql`FILTER TO_NUMBER(user._key) < TO_NUMBER(${beforeId})` + } else { + let beforeTemplateDirection = aql`` + if (orderBy.direction === 'ASC') { + beforeTemplateDirection = aql`<` } else { - let beforeTemplateDirection = aql`` - if (orderBy.direction === 'ASC') { - beforeTemplateDirection = aql`<` - } else { - beforeTemplateDirection = aql`>` - } + beforeTemplateDirection = aql`>` + } - beforeVar = aql`LET beforeVar = DOCUMENT(users, ${beforeId})` + beforeVar = aql`LET beforeVar = DOCUMENT(users, ${beforeId})` - let documentField = aql`` - let userField = aql`` - /* istanbul ignore else */ - if (orderBy.field === 'user-username') { - documentField = aql`beforeVar.userName` - userField = aql`user.userName` - } else if (orderBy.field === 'user-displayName') { - documentField = aql`beforeVar.displayName` - userField = aql`user.displayName` - } else if (orderBy.field === 'user-emailValidated') { - documentField = aql`beforeVar.emailValidated` - userField = aql`user.emailValidated` - } else if (orderBy.field === 'user-affiliations-totalCount') { - documentField = aql`beforeVar.affiliations.totalCount` - userField = aql`user.affiliations.totalCount` - } else if (orderBy.field === 'user-insider') { + let documentField = aql`` + let userField = aql`` + /* istanbul ignore else */ + if (orderBy.field === 'user-username') { + documentField = aql`beforeVar.userName` + userField = aql`user.userName` + } else if (orderBy.field === 'user-displayName') { + documentField = aql`beforeVar.displayName` + userField = aql`user.displayName` + } else if (orderBy.field === 'user-emailValidated') { + documentField = aql`beforeVar.emailValidated` + userField = aql`user.emailValidated` + } else if (orderBy.field === 'user-affiliations-totalCount') { + documentField = aql`beforeVar.affiliations.totalCount` + userField = aql`user.affiliations.totalCount` + } else if (orderBy.field === 'user-insider') { documentField = aql`beforeVar.insideUser` userField = aql`user.insideUser` } - beforeTemplate = aql` + beforeTemplate = aql` FILTER ${userField} ${beforeTemplateDirection} ${documentField} OR (${userField} == ${documentField} AND TO_NUMBER(user._key) < TO_NUMBER(${beforeId})) ` - } } + } - let limitTemplate = aql`` - if (typeof first === 'undefined' && typeof last === 'undefined') { + let limitTemplate = aql`` + if (typeof first === 'undefined' && typeof last === 'undefined') { + console.warn( + `User: ${userKey} did not have either \`first\` or \`last\` arguments set for: loadUserConnectionsByUserId.`, + ) + throw new Error( + i18n._(t`You must provide a \`first\` or \`last\` value to properly paginate the \`User\` connection.`), + ) + } else if (typeof first !== 'undefined' && typeof last !== 'undefined') { + console.warn( + `User: ${userKey} attempted to have \`first\` and \`last\` arguments set for: loadUserConnectionsByUserId.`, + ) + throw new Error( + i18n._(t`Passing both \`first\` and \`last\` to paginate the \`User\` connection is not supported.`), + ) + } else if (typeof first === 'number' || typeof last === 'number') { + /* istanbul ignore else */ + if (first < 0 || last < 0) { + const argSet = typeof first !== 'undefined' ? 'first' : 'last' console.warn( - `User: ${userKey} did not have either \`first\` or \`last\` arguments set for: loadUserConnectionsByUserId.`, + `User: ${userKey} attempted to have \`${argSet}\` set below zero for: loadUserConnectionsByUserId.`, ) - throw new Error( - i18n._( - t`You must provide a \`first\` or \`last\` value to properly paginate the \`User\` connection.`, - ), - ) - } else if (typeof first !== 'undefined' && typeof last !== 'undefined') { + throw new Error(i18n._(t`\`${argSet}\` on the \`User\` connection cannot be less than zero.`)) + } else if (first > 100 || last > 100) { + const argSet = typeof first !== 'undefined' ? 'first' : 'last' + const amount = typeof first !== 'undefined' ? first : last console.warn( - `User: ${userKey} attempted to have \`first\` and \`last\` arguments set for: loadUserConnectionsByUserId.`, + `User: ${userKey} attempted to have \`${argSet}\` set to ${amount} for: loadUserConnectionsByUserId.`, ) throw new Error( i18n._( - t`Passing both \`first\` and \`last\` to paginate the \`User\` connection is not supported.`, + t`Requesting \`${amount}\` records on the \`User\` connection exceeds the \`${argSet}\` limit of 100 records.`, ), ) - } else if (typeof first === 'number' || typeof last === 'number') { - /* istanbul ignore else */ - if (first < 0 || last < 0) { - const argSet = typeof first !== 'undefined' ? 'first' : 'last' - console.warn( - `User: ${userKey} attempted to have \`${argSet}\` set below zero for: loadUserConnectionsByUserId.`, - ) - throw new Error( - i18n._( - t`\`${argSet}\` on the \`User\` connection cannot be less than zero.`, - ), - ) - } else if (first > 100 || last > 100) { - const argSet = typeof first !== 'undefined' ? 'first' : 'last' - const amount = typeof first !== 'undefined' ? first : last - console.warn( - `User: ${userKey} attempted to have \`${argSet}\` set to ${amount} for: loadUserConnectionsByUserId.`, - ) - throw new Error( - i18n._( - t`Requesting \`${amount}\` records on the \`User\` connection exceeds the \`${argSet}\` limit of 100 records.`, - ), - ) - } else if (typeof first !== 'undefined' && typeof last === 'undefined') { - limitTemplate = aql`TO_NUMBER(user._key) ASC LIMIT TO_NUMBER(${first})` - } else if (typeof first === 'undefined' && typeof last !== 'undefined') { - limitTemplate = aql`TO_NUMBER(user._key) DESC LIMIT TO_NUMBER(${last})` - } - } else { - const argSet = typeof first !== 'undefined' ? 'first' : 'last' - const typeSet = typeof first !== 'undefined' ? typeof first : typeof last - console.warn( - `User: ${userKey} attempted to have \`${argSet}\` set as a ${typeSet} for: loadUserConnectionsByUserId.`, - ) - throw new Error( - i18n._(t`\`${argSet}\` must be of type \`number\` not \`${typeSet}\`.`), - ) + } else if (typeof first !== 'undefined' && typeof last === 'undefined') { + limitTemplate = aql`TO_NUMBER(user._key) ASC LIMIT TO_NUMBER(${first})` + } else if (typeof first === 'undefined' && typeof last !== 'undefined') { + limitTemplate = aql`TO_NUMBER(user._key) DESC LIMIT TO_NUMBER(${last})` } + } else { + const argSet = typeof first !== 'undefined' ? 'first' : 'last' + const typeSet = typeof first !== 'undefined' ? typeof first : typeof last + console.warn( + `User: ${userKey} attempted to have \`${argSet}\` set as a ${typeSet} for: loadUserConnectionsByUserId.`, + ) + throw new Error(i18n._(t`\`${argSet}\` must be of type \`number\` not \`${typeSet}\`.`)) + } - let hasNextPageFilter = aql`FILTER TO_NUMBER(user._key) > TO_NUMBER(LAST(retrievedUsers)._key)` - let hasPreviousPageFilter = aql`FILTER TO_NUMBER(user._key) < TO_NUMBER(FIRST(retrievedUsers)._key)` - if (typeof orderBy !== 'undefined') { - let hasNextPageDirection = aql`` - let hasPreviousPageDirection = aql`` - if (orderBy.direction === 'ASC') { - hasNextPageDirection = aql`>` - hasPreviousPageDirection = aql`<` - } else { - hasNextPageDirection = aql`<` - hasPreviousPageDirection = aql`>` - } + let hasNextPageFilter = aql`FILTER TO_NUMBER(user._key) > TO_NUMBER(LAST(retrievedUsers)._key)` + let hasPreviousPageFilter = aql`FILTER TO_NUMBER(user._key) < TO_NUMBER(FIRST(retrievedUsers)._key)` + if (typeof orderBy !== 'undefined') { + let hasNextPageDirection = aql`` + let hasPreviousPageDirection = aql`` + if (orderBy.direction === 'ASC') { + hasNextPageDirection = aql`>` + hasPreviousPageDirection = aql`<` + } else { + hasNextPageDirection = aql`<` + hasPreviousPageDirection = aql`>` + } - let userField = aql`` - let hasNextPageDocumentField = aql`` - let hasPreviousPageDocumentField = aql`` - /* istanbul ignore else */ - if (orderBy.field === 'user-username') { - userField = aql`user.userName` - hasNextPageDocumentField = aql`LAST(retrievedUsers).userName` - hasPreviousPageDocumentField = aql`FIRST(retrievedUsers).userName` - } else if (orderBy.field === 'user-displayName') { - userField = aql`user.displayName` - hasNextPageDocumentField = aql`LAST(retrievedUsers).displayName` - hasPreviousPageDocumentField = aql`FIRST(retrievedUsers).displayName` - } else if (orderBy.field === 'user-emailValidated') { - userField = aql`user.emailValidated` - hasNextPageDocumentField = aql`LAST(retrievedUsers).emailValidated` - hasPreviousPageDocumentField = aql`FIRST(retrievedUsers).emailValidated` - } else if (orderBy.field === 'user-affiliations-totalCount') { - userField = aql`user.affiliations.totalCount` - hasNextPageDocumentField = aql`LAST(retrievedUsers).affiliations.totalCount` - hasPreviousPageDocumentField = aql`FIRST(retrievedUsers).affiliations.totalCount` - } else if (orderBy.field === 'user-insider') { + let userField = aql`` + let hasNextPageDocumentField = aql`` + let hasPreviousPageDocumentField = aql`` + /* istanbul ignore else */ + if (orderBy.field === 'user-username') { + userField = aql`user.userName` + hasNextPageDocumentField = aql`LAST(retrievedUsers).userName` + hasPreviousPageDocumentField = aql`FIRST(retrievedUsers).userName` + } else if (orderBy.field === 'user-displayName') { + userField = aql`user.displayName` + hasNextPageDocumentField = aql`LAST(retrievedUsers).displayName` + hasPreviousPageDocumentField = aql`FIRST(retrievedUsers).displayName` + } else if (orderBy.field === 'user-emailValidated') { + userField = aql`user.emailValidated` + hasNextPageDocumentField = aql`LAST(retrievedUsers).emailValidated` + hasPreviousPageDocumentField = aql`FIRST(retrievedUsers).emailValidated` + } else if (orderBy.field === 'user-affiliations-totalCount') { + userField = aql`user.affiliations.totalCount` + hasNextPageDocumentField = aql`LAST(retrievedUsers).affiliations.totalCount` + hasPreviousPageDocumentField = aql`FIRST(retrievedUsers).affiliations.totalCount` + } else if (orderBy.field === 'user-insider') { userField = aql`user.insideUser` hasNextPageDocumentField = aql`LAST(retrievedUsers).insideUser` hasPreviousPageDocumentField = aql`FIRST(retrievedUsers).insideUser` } - hasNextPageFilter = aql` + hasNextPageFilter = aql` FILTER ${userField} ${hasNextPageDirection} ${hasNextPageDocumentField} OR (${userField} == ${hasNextPageDocumentField} AND TO_NUMBER(user._key) > TO_NUMBER(LAST(retrievedUsers)._key)) ` - hasPreviousPageFilter = aql` + hasPreviousPageFilter = aql` FILTER ${userField} ${hasPreviousPageDirection} ${hasPreviousPageDocumentField} OR (${userField} == ${hasPreviousPageDocumentField} AND TO_NUMBER(user._key) < TO_NUMBER(FIRST(retrievedUsers)._key)) ` - } + } - let sortByField = aql`` - if (typeof orderBy !== 'undefined') { - /* istanbul ignore else */ - if (orderBy.field === 'user-username') { - sortByField = aql`user.userName ${orderBy.direction},` - } else if (orderBy.field === 'user-displayName') { - sortByField = aql`user.displayName ${orderBy.direction},` - } else if (orderBy.field === 'user-emailValidated') { - sortByField = aql`user.emailValidated ${orderBy.direction},` - } else if (orderBy.field === 'user-affiliations-totalCount') { - sortByField = aql`user.affiliations.totalCount ${orderBy.direction},` - } else if (orderBy.field === 'user-insider') { + let sortByField = aql`` + if (typeof orderBy !== 'undefined') { + /* istanbul ignore else */ + if (orderBy.field === 'user-username') { + sortByField = aql`user.userName ${orderBy.direction},` + } else if (orderBy.field === 'user-displayName') { + sortByField = aql`user.displayName ${orderBy.direction},` + } else if (orderBy.field === 'user-emailValidated') { + sortByField = aql`user.emailValidated ${orderBy.direction},` + } else if (orderBy.field === 'user-affiliations-totalCount') { + sortByField = aql`user.affiliations.totalCount ${orderBy.direction},` + } else if (orderBy.field === 'user-insider') { sortByField = aql`user.insideUser ${orderBy.direction},` } - } + } - let sortString - if (typeof last !== 'undefined') { - sortString = aql`DESC` - } else { - sortString = aql`ASC` - } + let sortString + if (typeof last !== 'undefined') { + sortString = aql`DESC` + } else { + sortString = aql`ASC` + } - let userKeysQuery - if (isSuperAdmin) { - userKeysQuery = aql` + let userKeysQuery + if (isSuperAdmin) { + userKeysQuery = aql` WITH users, userSearch, claims, organizations LET userKeys = ( FOR user IN users RETURN user._key ) ` - } else { - userKeysQuery = aql` + } else { + userKeysQuery = aql` WITH affiliations, organizations, users, userSearch, claims LET userKeys = UNIQUE(FLATTEN( LET keys = [] @@ -257,34 +247,45 @@ export const loadUserConnectionsByUserId = RETURN APPEND(keys, affiliationUserKeys) )) ` - } + } - let userSearchQuery = aql`` - let loopString = aql`FOR user IN users` - let totalCount = aql`LENGTH(userKeys)` - if (typeof search !== 'undefined' && search !== '') { - search = cleanseInput(search) - userSearchQuery = aql` + let userSearchQuery = aql`` + let loopString = aql`FOR user IN users` + let totalCount = aql`LENGTH(userKeys)` + if (typeof search !== 'undefined' && search !== '') { + search = cleanseInput(search) + userSearchQuery = aql` LET tokenArr = TOKENS(${search}, "text_en") - LET searchedUsers = ( + LET searchedDisplayNamesCount = FLATTEN( FOR tokenItem in tokenArr LET token = LOWER(tokenItem) FOR user IN userSearch SEARCH ANALYZER( user.displayName LIKE CONCAT("%", token, "%") - OR user.userName LIKE CONCAT("%", token, "%") , "text_en") FILTER user._key IN userKeys - RETURN user + COLLECT currentUser = user WITH COUNT INTO count + RETURN { + 'user': currentUser, + 'count': count + } + ) + LET searchedDisplayNames = searchedDisplayNamesCount[* FILTER CURRENT.count == LENGTH(tokenArr)].user + LET searchedUserNames = ( + FOR user IN users + FILTER LOWER(user.userName) LIKE CONCAT("%", LOWER(${search}), "%") + FILTER user._key IN userKeys + RETURN user ) + LET searchedUsers = UNIQUE(APPEND(searchedDisplayNames, searchedUserNames)) ` - loopString = aql`FOR user IN searchedUsers` - totalCount = aql`LENGTH(searchedUsers)` - } + loopString = aql`FOR user IN searchedUsers` + totalCount = aql`LENGTH(searchedUsers)` + } - let requestedUserInfo - try { - requestedUserInfo = await query` + let requestedUserInfo + try { + requestedUserInfo = await query` ${userKeysQuery} ${userSearchQuery} @@ -328,51 +329,51 @@ export const loadUserConnectionsByUserId = "endKey": LAST(retrievedUsers)._key } ` - } catch (err) { - console.error( - `Database error occurred while user: ${userKey} was trying to query users in loadUserConnectionsByUserId, error: ${err}`, - ) - throw new Error(i18n._(t`Unable to query user(s). Please try again.`)) - } - - let usersInfo - try { - usersInfo = await requestedUserInfo.next() - } catch (err) { - console.error( - `Cursor error occurred while user: ${userKey} was trying to gather users in loadUserConnectionsByUserId, error: ${err}`, - ) - throw new Error(i18n._(t`Unable to load user(s). Please try again.`)) - } - - if (usersInfo.users.length === 0) { - return { - edges: [], - totalCount: 0, - pageInfo: { - hasNextPage: false, - hasPreviousPage: false, - startCursor: '', - endCursor: '', - }, - } - } + } catch (err) { + console.error( + `Database error occurred while user: ${userKey} was trying to query users in loadUserConnectionsByUserId, error: ${err}`, + ) + throw new Error(i18n._(t`Unable to query user(s). Please try again.`)) + } - const edges = usersInfo.users.map((user) => { - return { - cursor: toGlobalId('user', user._key), - node: user, - } - }) + let usersInfo + try { + usersInfo = await requestedUserInfo.next() + } catch (err) { + console.error( + `Cursor error occurred while user: ${userKey} was trying to gather users in loadUserConnectionsByUserId, error: ${err}`, + ) + throw new Error(i18n._(t`Unable to load user(s). Please try again.`)) + } + if (usersInfo.users.length === 0) { return { - edges, - totalCount: usersInfo.totalCount, + edges: [], + totalCount: 0, pageInfo: { - hasNextPage: usersInfo.hasNextPage, - hasPreviousPage: usersInfo.hasPreviousPage, - startCursor: toGlobalId('user', usersInfo.startKey), - endCursor: toGlobalId('user', usersInfo.endKey), + hasNextPage: false, + hasPreviousPage: false, + startCursor: '', + endCursor: '', }, } } + + const edges = usersInfo.users.map((user) => { + return { + cursor: toGlobalId('user', user._key), + node: user, + } + }) + + return { + edges, + totalCount: usersInfo.totalCount, + pageInfo: { + hasNextPage: usersInfo.hasNextPage, + hasPreviousPage: usersInfo.hasPreviousPage, + startCursor: toGlobalId('user', usersInfo.startKey), + endCursor: toGlobalId('user', usersInfo.endKey), + }, + } + } diff --git a/api/src/user/mutations/__tests__/authenticate.test.js b/api/src/user/mutations/__tests__/authenticate.test.js index d1550aed7a..363cf6007c 100644 --- a/api/src/user/mutations/__tests__/authenticate.test.js +++ b/api/src/user/mutations/__tests__/authenticate.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import bcrypt from 'bcryptjs' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/user/mutations/__tests__/close-account.test.js b/api/src/user/mutations/__tests__/close-account.test.js index 4e698f32bb..597cd6dbe6 100644 --- a/api/src/user/mutations/__tests__/close-account.test.js +++ b/api/src/user/mutations/__tests__/close-account.test.js @@ -1,5 +1,6 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/user/mutations/__tests__/refresh-tokens.test.js b/api/src/user/mutations/__tests__/refresh-tokens.test.js index 08fa90f685..a5990bed5a 100644 --- a/api/src/user/mutations/__tests__/refresh-tokens.test.js +++ b/api/src/user/mutations/__tests__/refresh-tokens.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' import { v4 as uuidv4 } from 'uuid' diff --git a/api/src/user/mutations/__tests__/remove-phone-number.test.js b/api/src/user/mutations/__tests__/remove-phone-number.test.js index 99b8add2de..b36c4463b5 100644 --- a/api/src/user/mutations/__tests__/remove-phone-number.test.js +++ b/api/src/user/mutations/__tests__/remove-phone-number.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/user/mutations/__tests__/reset-password.test.js b/api/src/user/mutations/__tests__/reset-password.test.js index 4dc308c374..2c6adc88a7 100644 --- a/api/src/user/mutations/__tests__/reset-password.test.js +++ b/api/src/user/mutations/__tests__/reset-password.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import bcrypt from 'bcryptjs' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/user/mutations/__tests__/send-email-verification.test.js b/api/src/user/mutations/__tests__/send-email-verification.test.js index 9798307f2d..f20373b949 100644 --- a/api/src/user/mutations/__tests__/send-email-verification.test.js +++ b/api/src/user/mutations/__tests__/send-email-verification.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import bcrypt from 'bcryptjs' import { graphql, GraphQLSchema } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/user/mutations/__tests__/send-password-reset.test.js b/api/src/user/mutations/__tests__/send-password-reset.test.js index 7d303a5ab3..1b737e5241 100644 --- a/api/src/user/mutations/__tests__/send-password-reset.test.js +++ b/api/src/user/mutations/__tests__/send-password-reset.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import bcrypt from 'bcryptjs' import { graphql, GraphQLSchema } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/user/mutations/__tests__/set-phone-number.test.js b/api/src/user/mutations/__tests__/set-phone-number.test.js index 22914afcda..d36f5512b9 100644 --- a/api/src/user/mutations/__tests__/set-phone-number.test.js +++ b/api/src/user/mutations/__tests__/set-phone-number.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import bcrypt from 'bcryptjs' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/user/mutations/__tests__/sign-in.test.js b/api/src/user/mutations/__tests__/sign-in.test.js index 177debe1db..f0c55754bc 100644 --- a/api/src/user/mutations/__tests__/sign-in.test.js +++ b/api/src/user/mutations/__tests__/sign-in.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import bcrypt from 'bcryptjs' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/user/mutations/__tests__/sign-up.test.js b/api/src/user/mutations/__tests__/sign-up.test.js index 9262dd2bec..1e3b4a0204 100644 --- a/api/src/user/mutations/__tests__/sign-up.test.js +++ b/api/src/user/mutations/__tests__/sign-up.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import bcrypt from 'bcryptjs' import { graphql, GraphQLError, GraphQLSchema } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/user/mutations/__tests__/update-user-password.test.js b/api/src/user/mutations/__tests__/update-user-password.test.js index 29c2c91056..1b0eb07dfe 100644 --- a/api/src/user/mutations/__tests__/update-user-password.test.js +++ b/api/src/user/mutations/__tests__/update-user-password.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import bcrypt from 'bcryptjs' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/user/mutations/__tests__/update-user-profile.test.js b/api/src/user/mutations/__tests__/update-user-profile.test.js index a74d8130b9..fdc123717c 100644 --- a/api/src/user/mutations/__tests__/update-user-profile.test.js +++ b/api/src/user/mutations/__tests__/update-user-profile.test.js @@ -1,6 +1,7 @@ import bcrypt from 'bcryptjs' import crypto from 'crypto' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/user/mutations/__tests__/verify-account.test.js b/api/src/user/mutations/__tests__/verify-account.test.js index 3f1ac533d5..5eaa4b763e 100644 --- a/api/src/user/mutations/__tests__/verify-account.test.js +++ b/api/src/user/mutations/__tests__/verify-account.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/user/mutations/__tests__/verify-phone-number.test.js b/api/src/user/mutations/__tests__/verify-phone-number.test.js index 649ab30d5f..31188f0968 100644 --- a/api/src/user/mutations/__tests__/verify-phone-number.test.js +++ b/api/src/user/mutations/__tests__/verify-phone-number.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/user/queries/__tests__/find-me.test.js b/api/src/user/queries/__tests__/find-me.test.js index 707c92a766..96bb01894d 100644 --- a/api/src/user/queries/__tests__/find-me.test.js +++ b/api/src/user/queries/__tests__/find-me.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/user/queries/__tests__/find-my-tracker.test.js b/api/src/user/queries/__tests__/find-my-tracker.test.js index 8170e2b265..fe8ac8954b 100644 --- a/api/src/user/queries/__tests__/find-my-tracker.test.js +++ b/api/src/user/queries/__tests__/find-my-tracker.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { setupI18n } from '@lingui/core' diff --git a/api/src/user/queries/__tests__/find-my-users.test.js b/api/src/user/queries/__tests__/find-my-users.test.js index 0d3da251dd..7047df7cee 100644 --- a/api/src/user/queries/__tests__/find-my-users.test.js +++ b/api/src/user/queries/__tests__/find-my-users.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/user/queries/__tests__/find-user-by-username.test.js b/api/src/user/queries/__tests__/find-user-by-username.test.js index 32690059e8..0e0d8a988a 100644 --- a/api/src/user/queries/__tests__/find-user-by-username.test.js +++ b/api/src/user/queries/__tests__/find-user-by-username.test.js @@ -1,5 +1,6 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/user/queries/__tests__/is-user-admin.test.js b/api/src/user/queries/__tests__/is-user-admin.test.js index 536ad86a22..9a9c449856 100644 --- a/api/src/user/queries/__tests__/is-user-admin.test.js +++ b/api/src/user/queries/__tests__/is-user-admin.test.js @@ -1,5 +1,6 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLError, GraphQLSchema } from 'graphql' import { toGlobalId } from 'graphql-relay' diff --git a/api/src/user/queries/__tests__/is-user-super-admin.test.js b/api/src/user/queries/__tests__/is-user-super-admin.test.js index 844239b721..1f657eb74d 100644 --- a/api/src/user/queries/__tests__/is-user-super-admin.test.js +++ b/api/src/user/queries/__tests__/is-user-super-admin.test.js @@ -1,5 +1,6 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLError, GraphQLSchema } from 'graphql' import { checkPermission, userRequired } from '../../../auth' diff --git a/api/src/verified-domains/loaders/__tests__/load-verified-domain-by-domain.test.js b/api/src/verified-domains/loaders/__tests__/load-verified-domain-by-domain.test.js index a1afd825de..55ea1176cf 100644 --- a/api/src/verified-domains/loaders/__tests__/load-verified-domain-by-domain.test.js +++ b/api/src/verified-domains/loaders/__tests__/load-verified-domain-by-domain.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' @@ -22,16 +23,16 @@ describe('given a loadVerifiedDomainsById dataloader', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, - - schema: dbschema, - })) + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, + + schema: dbschema, + })) }) beforeEach(async () => { org = await collections.organizations.save({ @@ -135,17 +136,13 @@ describe('given a loadVerifiedDomainsById dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadVerifiedDomainsById({ query: mockedQuery, i18n }) try { await loader.load('domain.ca') } catch (err) { - expect(err).toEqual( - new Error('Unable to load verified domain(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load verified domain(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -166,9 +163,7 @@ describe('given a loadVerifiedDomainsById dataloader', () => { try { await loader.load('domain.ca') } catch (err) { - expect(err).toEqual( - new Error('Unable to load verified domain(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load verified domain(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -194,19 +189,13 @@ describe('given a loadVerifiedDomainsById dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadVerifiedDomainsById({ query: mockedQuery, i18n }) try { await loader.load('domain.ca') } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ @@ -227,11 +216,7 @@ describe('given a loadVerifiedDomainsById dataloader', () => { try { await loader.load('domain.ca') } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ diff --git a/api/src/verified-domains/loaders/__tests__/load-verified-domain-by-key.test.js b/api/src/verified-domains/loaders/__tests__/load-verified-domain-by-key.test.js index f5f485a18b..0fc8226a6c 100644 --- a/api/src/verified-domains/loaders/__tests__/load-verified-domain-by-key.test.js +++ b/api/src/verified-domains/loaders/__tests__/load-verified-domain-by-key.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' @@ -22,16 +23,16 @@ describe('given a loadVerifiedDomainByKey dataloader', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, - - schema: dbschema, - })) + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, + + schema: dbschema, + })) }) beforeEach(async () => { org = await collections.organizations.save({ @@ -135,17 +136,13 @@ describe('given a loadVerifiedDomainByKey dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadVerifiedDomainByKey({ query: mockedQuery, i18n }) try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error('Unable to load verified domain(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load verified domain(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -166,9 +163,7 @@ describe('given a loadVerifiedDomainByKey dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error('Unable to load verified domain(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load verified domain(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -194,19 +189,13 @@ describe('given a loadVerifiedDomainByKey dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadVerifiedDomainByKey({ query: mockedQuery, i18n }) try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ @@ -227,11 +216,7 @@ describe('given a loadVerifiedDomainByKey dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ diff --git a/api/src/verified-domains/loaders/__tests__/load-verified-domain-conn-by-org-id.test.js b/api/src/verified-domains/loaders/__tests__/load-verified-domain-conn-by-org-id.test.js index fdb966208a..4c4719267f 100644 --- a/api/src/verified-domains/loaders/__tests__/load-verified-domain-conn-by-org-id.test.js +++ b/api/src/verified-domains/loaders/__tests__/load-verified-domain-conn-by-org-id.test.js @@ -1,15 +1,13 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { stringify } from 'jest-matcher-utils' import { toGlobalId } from 'graphql-relay' import englishMessages from '../../../locale/en/messages' import frenchMessages from '../../../locale/fr/messages' import { cleanseInput } from '../../../validators' -import { - loadVerifiedDomainConnectionsByOrgId, - loadVerifiedDomainByKey, -} from '../../loaders' +import { loadVerifiedDomainConnectionsByOrgId, loadVerifiedDomainByKey } from '../../loaders' import dbschema from '../../../../database.json' const { DB_PASS: rootPass, DB_URL: url } = process.env @@ -30,16 +28,16 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, - - schema: dbschema, - })) + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, + + schema: dbschema, + })) }) beforeEach(async () => { user = await collections.users.save({ @@ -108,10 +106,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { }) const domainLoader = loadVerifiedDomainByKey({ query }) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -154,10 +149,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { }) const domainLoader = loadVerifiedDomainByKey({ query }) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -200,10 +192,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { }) const domainLoader = loadVerifiedDomainByKey({ query }) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -245,10 +234,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { }) const domainLoader = loadVerifiedDomainByKey({ query }) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -1110,11 +1096,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` on the `VerifiedDomain` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`first` on the `VerifiedDomain` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ @@ -1139,11 +1121,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` on the `VerifiedDomain` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`last` on the `VerifiedDomain` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ @@ -1215,9 +1193,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadVerifiedDomainConnectionsByOrgId({ query, cleanseInput, @@ -1234,11 +1210,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User attempted to have \`first\` set as a ${typeof invalidInput} for: loadVerifiedDomainConnectionsByOrgId.`, @@ -1248,9 +1220,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadVerifiedDomainConnectionsByOrgId({ query, cleanseInput, @@ -1267,11 +1237,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User attempted to have \`last\` set as a ${typeof invalidInput} for: loadVerifiedDomainConnectionsByOrgId.`, @@ -1284,9 +1250,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { describe('given a database error', () => { describe('when gathering domain keys that are claimed by orgs that the user has affiliations to', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database Error Occurred.')) + const query = jest.fn().mockRejectedValue(new Error('Database Error Occurred.')) const connectionLoader = loadVerifiedDomainConnectionsByOrgId({ query, @@ -1303,9 +1267,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load verified domain(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load verified domain(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -1339,9 +1301,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load verified domain(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load verified domain(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -1442,11 +1402,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` sur la connexion `VerifiedDomain` ne peut être inférieur à zéro.', - ), - ) + expect(err).toEqual(new Error('`first` sur la connexion `VerifiedDomain` ne peut être inférieur à zéro.')) } expect(consoleOutput).toEqual([ @@ -1471,11 +1427,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` sur la connexion `VerifiedDomain` ne peut être inférieur à zéro.', - ), - ) + expect(err).toEqual(new Error('`last` sur la connexion `VerifiedDomain` ne peut être inférieur à zéro.')) } expect(consoleOutput).toEqual([ @@ -1547,9 +1499,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadVerifiedDomainConnectionsByOrgId({ query, cleanseInput, @@ -1567,9 +1517,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -1580,9 +1528,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadVerifiedDomainConnectionsByOrgId({ query, cleanseInput, @@ -1600,9 +1546,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -1616,9 +1560,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { describe('given a database error', () => { describe('when gathering domain keys that are claimed by orgs that the user has affiliations to', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database Error Occurred.')) + const query = jest.fn().mockRejectedValue(new Error('Database Error Occurred.')) const connectionLoader = loadVerifiedDomainConnectionsByOrgId({ query, @@ -1635,11 +1577,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ @@ -1673,11 +1611,7 @@ describe('given the loadVerifiedDomainConnectionsByOrgId function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ diff --git a/api/src/verified-domains/loaders/__tests__/load-verified-domain-connections.test.js b/api/src/verified-domains/loaders/__tests__/load-verified-domain-connections.test.js index cba8bbeec9..b143ae06e7 100644 --- a/api/src/verified-domains/loaders/__tests__/load-verified-domain-connections.test.js +++ b/api/src/verified-domains/loaders/__tests__/load-verified-domain-connections.test.js @@ -1,15 +1,13 @@ import { setupI18n } from '@lingui/core' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { stringify } from 'jest-matcher-utils' import { toGlobalId } from 'graphql-relay' import englishMessages from '../../../locale/en/messages' import frenchMessages from '../../../locale/fr/messages' import { cleanseInput } from '../../../validators' -import { - loadVerifiedDomainConnections, - loadVerifiedDomainByKey, -} from '../../loaders' +import { loadVerifiedDomainConnections, loadVerifiedDomainByKey } from '../../loaders' import dbschema from '../../../../database.json' const { DB_PASS: rootPass, DB_URL: url } = process.env @@ -30,16 +28,16 @@ describe('given the load domain connection using org id function', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, - - schema: dbschema, - })) + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, + + schema: dbschema, + })) }) beforeEach(async () => { user = await collections.users.save({ @@ -108,10 +106,7 @@ describe('given the load domain connection using org id function', () => { }) const domainLoader = loadVerifiedDomainByKey({ query }) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -153,10 +148,7 @@ describe('given the load domain connection using org id function', () => { }) const domainLoader = loadVerifiedDomainByKey({ query }) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -198,10 +190,7 @@ describe('given the load domain connection using org id function', () => { }) const domainLoader = loadVerifiedDomainByKey({ query }) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -242,10 +231,7 @@ describe('given the load domain connection using org id function', () => { }) const domainLoader = loadVerifiedDomainByKey({ query }) - const expectedDomains = await domainLoader.loadMany([ - domain._key, - domainTwo._key, - ]) + const expectedDomains = await domainLoader.loadMany([domain._key, domainTwo._key]) expectedDomains[0].id = expectedDomains[0]._key expectedDomains[1].id = expectedDomains[1]._key @@ -1088,11 +1074,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` on the `VerifiedDomain` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`first` on the `VerifiedDomain` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ @@ -1116,11 +1098,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` on the `VerifiedDomain` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`last` on the `VerifiedDomain` connection cannot be less than zero.')) } expect(consoleOutput).toEqual([ @@ -1190,9 +1168,7 @@ describe('given the load domain connection using org id function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadVerifiedDomainConnections({ query, cleanseInput, @@ -1208,11 +1184,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User attempted to have \`first\` set as a ${typeof invalidInput} for: loadVerifiedDomainConnections.`, @@ -1222,9 +1194,7 @@ describe('given the load domain connection using org id function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadVerifiedDomainConnections({ query, cleanseInput, @@ -1240,11 +1210,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User attempted to have \`last\` set as a ${typeof invalidInput} for: loadVerifiedDomainConnections.`, @@ -1257,9 +1223,7 @@ describe('given the load domain connection using org id function', () => { describe('given a database error', () => { describe('when gathering domain keys that are claimed by orgs that the user has affiliations to', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database Error Occurred.')) + const query = jest.fn().mockRejectedValue(new Error('Database Error Occurred.')) const connectionLoader = loadVerifiedDomainConnections({ query, @@ -1275,9 +1239,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load verified domain(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load verified domain(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -1311,9 +1273,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error('Unable to load verified domain(s). Please try again.'), - ) + expect(err).toEqual(new Error('Unable to load verified domain(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -1411,11 +1371,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` sur la connexion `VerifiedDomain` ne peut être inférieur à zéro.', - ), - ) + expect(err).toEqual(new Error('`first` sur la connexion `VerifiedDomain` ne peut être inférieur à zéro.')) } expect(consoleOutput).toEqual([ @@ -1439,11 +1395,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` sur la connexion `VerifiedDomain` ne peut être inférieur à zéro.', - ), - ) + expect(err).toEqual(new Error('`last` sur la connexion `VerifiedDomain` ne peut être inférieur à zéro.')) } expect(consoleOutput).toEqual([ @@ -1513,9 +1465,7 @@ describe('given the load domain connection using org id function', () => { describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadVerifiedDomainConnections({ query, cleanseInput, @@ -1532,9 +1482,7 @@ describe('given the load domain connection using org id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -1545,9 +1493,7 @@ describe('given the load domain connection using org id function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadVerifiedDomainConnections({ query, cleanseInput, @@ -1564,9 +1510,7 @@ describe('given the load domain connection using org id function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -1580,9 +1524,7 @@ describe('given the load domain connection using org id function', () => { describe('given a database error', () => { describe('when gathering domain keys that are claimed by orgs that the user has affiliations to', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database Error Occurred.')) + const query = jest.fn().mockRejectedValue(new Error('Database Error Occurred.')) const connectionLoader = loadVerifiedDomainConnections({ query, @@ -1598,11 +1540,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ @@ -1635,11 +1573,7 @@ describe('given the load domain connection using org id function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) domaine(s) vérifié(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ diff --git a/api/src/verified-domains/queries/__tests__/find-verified-domain-by-domain.test.js b/api/src/verified-domains/queries/__tests__/find-verified-domain-by-domain.test.js index 98dfab8a49..c9a4463a0a 100644 --- a/api/src/verified-domains/queries/__tests__/find-verified-domain-by-domain.test.js +++ b/api/src/verified-domains/queries/__tests__/find-verified-domain-by-domain.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/verified-domains/queries/__tests__/find-verified-domains.test.js b/api/src/verified-domains/queries/__tests__/find-verified-domains.test.js index 16d66525de..6857181e3b 100644 --- a/api/src/verified-domains/queries/__tests__/find-verified-domains.test.js +++ b/api/src/verified-domains/queries/__tests__/find-verified-domains.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/verified-organizations/loaders/__tests__/load-verified-org-conn-by-domain-id.test.js b/api/src/verified-organizations/loaders/__tests__/load-verified-org-conn-by-domain-id.test.js index a1321e4bbf..b7ad6383d9 100644 --- a/api/src/verified-organizations/loaders/__tests__/load-verified-org-conn-by-domain-id.test.js +++ b/api/src/verified-organizations/loaders/__tests__/load-verified-org-conn-by-domain-id.test.js @@ -1,15 +1,13 @@ import { stringify } from 'jest-matcher-utils' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' import frenchMessages from '../../../locale/fr/messages' import { cleanseInput } from '../../../validators' -import { - loadVerifiedOrgConnectionsByDomainId, - loadVerifiedOrgByKey, -} from '../../loaders' +import { loadVerifiedOrgConnectionsByDomainId, loadVerifiedOrgByKey } from '../../loaders' import dbschema from '../../../../database.json' const { DB_PASS: rootPass, DB_URL: url } = process.env @@ -163,28 +161,20 @@ describe('given the load organizations connection function', () => { console.error = mockedError console.warn = mockedWarn - let query, - drop, - truncate, - collections, - org, - orgTwo, - domain, - domainTwo, - domainThree + let query, drop, truncate, collections, org, orgTwo, domain, domainTwo, domainThree beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, - schema: dbschema, - })) + schema: dbschema, + })) }) beforeEach(async () => { org = await collections.organizations.save(orgOneData) @@ -249,10 +239,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), node: { ...expectedOrgs[1], }, @@ -262,14 +249,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), }, } @@ -283,28 +264,20 @@ describe('given the load organizations connection function', () => { console.error = mockedError console.warn = mockedWarn - let query, - drop, - truncate, - collections, - org, - orgTwo, - domain, - domainTwo, - domainThree + let query, drop, truncate, collections, org, orgTwo, domain, domainTwo, domainThree beforeEach(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, - schema: dbschema, - })) + schema: dbschema, + })) org = await collections.organizations.save(orgOneData) orgTwo = await collections.organizations.save(orgTwoData) @@ -367,10 +340,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), node: { ...expectedOrgs[0], }, @@ -380,14 +350,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), }, } @@ -401,28 +365,20 @@ describe('given the load organizations connection function', () => { console.error = mockedError console.warn = mockedWarn - let query, - drop, - truncate, - collections, - org, - orgTwo, - domain, - domainTwo, - domainThree + let query, drop, truncate, collections, org, orgTwo, domain, domainTwo, domainThree beforeEach(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, - schema: dbschema, - })) + schema: dbschema, + })) org = await collections.organizations.save(orgOneData) orgTwo = await collections.organizations.save(orgTwoData) @@ -484,10 +440,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), node: { ...expectedOrgs[0], }, @@ -497,14 +450,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), }, } @@ -518,28 +465,20 @@ describe('given the load organizations connection function', () => { console.error = mockedError console.warn = mockedWarn - let query, - drop, - truncate, - collections, - org, - orgTwo, - domain, - domainTwo, - domainThree + let query, drop, truncate, collections, org, orgTwo, domain, domainTwo, domainThree beforeEach(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, - schema: dbschema, - })) + schema: dbschema, + })) org = await collections.organizations.save(orgOneData) orgTwo = await collections.organizations.save(orgTwoData) @@ -601,10 +540,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), node: { ...expectedOrgs[1], }, @@ -614,14 +550,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), }, } @@ -635,29 +565,20 @@ describe('given the load organizations connection function', () => { console.error = mockedError console.warn = mockedWarn - let query, - drop, - truncate, - collections, - org, - orgTwo, - domain, - domainTwo, - domainThree, - orgThree + let query, drop, truncate, collections, org, orgTwo, domain, domainTwo, domainThree, orgThree beforeEach(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, - schema: dbschema, - })) + schema: dbschema, + })) org = await collections.organizations.save(orgOneData) orgTwo = await collections.organizations.save(orgTwoData) @@ -738,10 +659,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -751,14 +669,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -798,10 +710,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -811,14 +720,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -860,10 +763,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -873,14 +773,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -920,10 +814,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -933,14 +824,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -982,10 +867,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -995,14 +877,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1042,10 +918,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1055,14 +928,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1104,10 +971,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1117,14 +981,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1165,10 +1023,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1178,14 +1033,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1227,10 +1076,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1240,14 +1086,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1287,10 +1127,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1300,14 +1137,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1349,10 +1180,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1362,14 +1190,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1409,10 +1231,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1422,14 +1241,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1471,10 +1284,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1484,14 +1294,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1531,10 +1335,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1544,14 +1345,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1593,10 +1388,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1606,14 +1398,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1653,10 +1439,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1666,14 +1449,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1715,10 +1492,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1728,14 +1502,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1775,10 +1543,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1788,14 +1553,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1837,10 +1596,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1850,14 +1606,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1897,10 +1647,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1910,14 +1657,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1960,10 +1701,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1973,14 +1711,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2020,10 +1752,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2033,14 +1762,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2082,10 +1805,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2095,14 +1815,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2143,10 +1857,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2156,14 +1867,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2177,16 +1882,16 @@ describe('given the load organizations connection function', () => { beforeEach(async () => { ;({ query, drop } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, - schema: dbschema, - })) + schema: dbschema, + })) }) afterAll(async () => { @@ -2270,9 +1975,7 @@ describe('given the load organizations connection function', () => { } expect(console.warn.mock.calls).toEqual([ - [ - 'User did not have either `first` or `last` arguments set for: loadVerifiedOrgConnectionsByDomainId.', - ], + ['User did not have either `first` or `last` arguments set for: loadVerifiedOrgConnectionsByDomainId.'], ]) }) }) @@ -2310,9 +2013,7 @@ describe('given the load organizations connection function', () => { } expect(console.warn.mock.calls).toEqual([ - [ - 'User attempted to have `first` and `last` arguments set for: loadVerifiedOrgConnectionsByDomainId.', - ], + ['User attempted to have `first` and `last` arguments set for: loadVerifiedOrgConnectionsByDomainId.'], ]) }) }) @@ -2341,17 +2042,11 @@ describe('given the load organizations connection function', () => { first: -1, }) } catch (err) { - expect(err).toEqual( - new Error( - '`first` on the `VerifiedOrganization` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`first` on the `VerifiedOrganization` connection cannot be less than zero.')) } expect(console.warn.mock.calls).toEqual([ - [ - 'User attempted to have `first` set below zero for: loadVerifiedOrgConnectionsByDomainId.', - ], + ['User attempted to have `first` set below zero for: loadVerifiedOrgConnectionsByDomainId.'], ]) }) }) @@ -2379,17 +2074,11 @@ describe('given the load organizations connection function', () => { last: -1, }) } catch (err) { - expect(err).toEqual( - new Error( - '`last` on the `VerifiedOrganization` connection cannot be less than zero.', - ), - ) + expect(err).toEqual(new Error('`last` on the `VerifiedOrganization` connection cannot be less than zero.')) } expect(console.warn.mock.calls).toEqual([ - [ - 'User attempted to have `last` set below zero for: loadVerifiedOrgConnectionsByDomainId.', - ], + ['User attempted to have `last` set below zero for: loadVerifiedOrgConnectionsByDomainId.'], ]) }) }) @@ -2426,9 +2115,7 @@ describe('given the load organizations connection function', () => { } expect(console.warn.mock.calls).toEqual([ - [ - 'User attempted to have `first` to 101 for: loadVerifiedOrgConnectionsByDomainId.', - ], + ['User attempted to have `first` to 101 for: loadVerifiedOrgConnectionsByDomainId.'], ]) }) }) @@ -2465,9 +2152,7 @@ describe('given the load organizations connection function', () => { } expect(console.warn.mock.calls).toEqual([ - [ - 'User attempted to have `last` to 101 for: loadVerifiedOrgConnectionsByDomainId.', - ], + ['User attempted to have `last` to 101 for: loadVerifiedOrgConnectionsByDomainId.'], ]) }) }) @@ -2493,19 +2178,13 @@ describe('given the load organizations connection function', () => { afterAll(() => { console.warn = warn }) - it(`returns an error when first set is to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set is to ${stringify(invalidInput)}`, async () => { try { await connectionLoader({ first: invalidInput, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(console.warn.mock.calls).toEqual([ [ @@ -2536,19 +2215,13 @@ describe('given the load organizations connection function', () => { afterAll(() => { console.warn = warn }) - it(`returns an error when last is set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last is set to ${stringify(invalidInput)}`, async () => { try { await connectionLoader({ last: invalidInput, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(console.warn.mock.calls).toEqual([ [ @@ -2566,9 +2239,7 @@ describe('given the load organizations connection function', () => { console.error = jest.fn() const connectionLoader = loadVerifiedOrgConnectionsByDomainId({ - query: jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')), + query: jest.fn().mockRejectedValue(new Error('Database error occurred.')), language: 'en', cleanseInput, i18n, @@ -2579,9 +2250,7 @@ describe('given the load organizations connection function', () => { domainId: '1234', first: 5, }), - ).rejects.toThrow( - 'Unable to load verified organization(s). Please try again.', - ) + ).rejects.toThrow('Unable to load verified organization(s). Please try again.') expect(console.error.mock.calls).toEqual([ [ @@ -2614,9 +2283,7 @@ describe('given the load organizations connection function', () => { domainId: '1234', first: 5, }), - ).rejects.toThrow( - 'Unable to load verified organization(s). Please try again.', - ) + ).rejects.toThrow('Unable to load verified organization(s). Please try again.') expect(console.error.mock.calls).toEqual([ [ @@ -2674,9 +2341,7 @@ describe('given the load organizations connection function', () => { } expect(console.warn.mock.calls).toEqual([ - [ - 'User did not have either `first` or `last` arguments set for: loadVerifiedOrgConnectionsByDomainId.', - ], + ['User did not have either `first` or `last` arguments set for: loadVerifiedOrgConnectionsByDomainId.'], ]) }) }) @@ -2714,9 +2379,7 @@ describe('given the load organizations connection function', () => { } expect(console.warn.mock.calls).toEqual([ - [ - 'User attempted to have `first` and `last` arguments set for: loadVerifiedOrgConnectionsByDomainId.', - ], + ['User attempted to have `first` and `last` arguments set for: loadVerifiedOrgConnectionsByDomainId.'], ]) }) }) @@ -2746,16 +2409,12 @@ describe('given the load organizations connection function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`first` sur la connexion `VerifiedOrganization` ne peut être inférieur à zéro.', - ), + new Error('`first` sur la connexion `VerifiedOrganization` ne peut être inférieur à zéro.'), ) } expect(console.warn.mock.calls).toEqual([ - [ - 'User attempted to have `first` set below zero for: loadVerifiedOrgConnectionsByDomainId.', - ], + ['User attempted to have `first` set below zero for: loadVerifiedOrgConnectionsByDomainId.'], ]) }) }) @@ -2784,16 +2443,12 @@ describe('given the load organizations connection function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`last` sur la connexion `VerifiedOrganization` ne peut être inférieur à zéro.', - ), + new Error('`last` sur la connexion `VerifiedOrganization` ne peut être inférieur à zéro.'), ) } expect(console.warn.mock.calls).toEqual([ - [ - 'User attempted to have `last` set below zero for: loadVerifiedOrgConnectionsByDomainId.', - ], + ['User attempted to have `last` set below zero for: loadVerifiedOrgConnectionsByDomainId.'], ]) }) }) @@ -2830,9 +2485,7 @@ describe('given the load organizations connection function', () => { } expect(console.warn.mock.calls).toEqual([ - [ - 'User attempted to have `first` to 101 for: loadVerifiedOrgConnectionsByDomainId.', - ], + ['User attempted to have `first` to 101 for: loadVerifiedOrgConnectionsByDomainId.'], ]) }) }) @@ -2869,9 +2522,7 @@ describe('given the load organizations connection function', () => { } expect(console.warn.mock.calls).toEqual([ - [ - 'User attempted to have `last` to 101 for: loadVerifiedOrgConnectionsByDomainId.', - ], + ['User attempted to have `last` to 101 for: loadVerifiedOrgConnectionsByDomainId.'], ]) }) }) @@ -2897,18 +2548,14 @@ describe('given the load organizations connection function', () => { afterAll(() => { console.warn = warn }) - it(`returns an error when first set is to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set is to ${stringify(invalidInput)}`, async () => { try { await connectionLoader({ first: invalidInput, }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(console.warn.mock.calls).toEqual([ @@ -2940,18 +2587,14 @@ describe('given the load organizations connection function', () => { afterAll(() => { console.warn = warn }) - it(`returns an error when last is set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last is set to ${stringify(invalidInput)}`, async () => { try { await connectionLoader({ last: invalidInput, }) } catch (err) { expect(err).toEqual( - new Error( - `\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(console.warn.mock.calls).toEqual([ @@ -2970,9 +2613,7 @@ describe('given the load organizations connection function', () => { console.error = jest.fn() const connectionLoader = loadVerifiedOrgConnectionsByDomainId({ - query: jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')), + query: jest.fn().mockRejectedValue(new Error('Database error occurred.')), language: 'en', cleanseInput, i18n, @@ -2983,9 +2624,7 @@ describe('given the load organizations connection function', () => { domainId: '1234', first: 5, }), - ).rejects.toThrow( - 'Impossible de charger le(s) organisme(s) vérifié(s). Veuillez réessayer.', - ) + ).rejects.toThrow('Impossible de charger le(s) organisme(s) vérifié(s). Veuillez réessayer.') expect(console.error.mock.calls).toEqual([ [ @@ -3018,9 +2657,7 @@ describe('given the load organizations connection function', () => { domainId: '1234', first: 5, }), - ).rejects.toThrow( - 'Impossible de charger le(s) organisme(s) vérifié(s). Veuillez réessayer.', - ) + ).rejects.toThrow('Impossible de charger le(s) organisme(s) vérifié(s). Veuillez réessayer.') expect(console.error.mock.calls).toEqual([ [ diff --git a/api/src/verified-organizations/loaders/__tests__/load-verified-org-conn.test.js b/api/src/verified-organizations/loaders/__tests__/load-verified-org-conn.test.js index fb795727b1..95d76034cb 100644 --- a/api/src/verified-organizations/loaders/__tests__/load-verified-org-conn.test.js +++ b/api/src/verified-organizations/loaders/__tests__/load-verified-org-conn.test.js @@ -1,5 +1,6 @@ import { stringify } from 'jest-matcher-utils' -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' @@ -12,16 +13,7 @@ import dbschema from '../../../../database.json' const { DB_PASS: rootPass, DB_URL: url } = process.env describe('given the load organizations connection function', () => { - let query, - drop, - truncate, - collections, - org, - orgTwo, - i18n, - domain, - domainTwo, - domainThree + let query, drop, truncate, collections, org, orgTwo, i18n, domain, domainTwo, domainThree const consoleOutput = [] const mockedError = (output) => consoleOutput.push(output) @@ -37,16 +29,16 @@ describe('given the load organizations connection function', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, - - schema: dbschema, - })) + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, + + schema: dbschema, + })) }) beforeEach(async () => { org = await collections.organizations.save({ @@ -196,10 +188,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), node: { ...expectedOrgs[1], }, @@ -209,14 +198,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), }, } @@ -249,10 +232,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), node: { ...expectedOrgs[0], }, @@ -262,14 +242,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), }, } @@ -301,10 +275,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), node: { ...expectedOrgs[0], }, @@ -314,14 +285,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), }, } @@ -353,10 +318,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), node: { ...expectedOrgs[1], }, @@ -366,14 +328,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), }, } @@ -462,10 +418,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -475,14 +428,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -521,10 +468,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -534,14 +478,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -582,10 +520,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -595,14 +530,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -641,10 +570,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -654,14 +580,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -702,10 +622,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -715,14 +632,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -761,10 +672,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -774,14 +682,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -822,10 +724,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -835,14 +734,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -881,10 +774,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -894,14 +784,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -942,10 +826,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -955,14 +836,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1001,10 +876,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1014,14 +886,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1062,10 +928,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1075,14 +938,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1121,10 +978,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1134,14 +988,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1182,10 +1030,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1195,14 +1040,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1241,10 +1080,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1254,14 +1090,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1302,10 +1132,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1315,14 +1142,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1361,10 +1182,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1374,14 +1192,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1422,10 +1234,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1435,14 +1244,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1481,10 +1284,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1494,14 +1294,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1542,10 +1336,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1555,14 +1346,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1601,10 +1386,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1614,14 +1396,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1662,10 +1438,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1675,14 +1448,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1721,10 +1488,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1734,14 +1498,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1782,10 +1540,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1795,14 +1550,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1841,10 +1590,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -1854,14 +1600,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -1944,10 +1684,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), node: { ...expectedOrgs[1], }, @@ -1957,14 +1694,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), }, } @@ -1997,10 +1728,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), node: { ...expectedOrgs[0], }, @@ -2010,14 +1738,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), }, } @@ -2049,10 +1771,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), node: { ...expectedOrgs[0], }, @@ -2062,14 +1781,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: false, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[0]._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrgs[0]._key), }, } @@ -2101,10 +1814,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), node: { ...expectedOrgs[1], }, @@ -2114,14 +1824,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: false, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrgs[1]._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrgs[1]._key), }, } @@ -2210,10 +1914,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2223,14 +1924,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2269,10 +1964,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2282,14 +1974,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2330,10 +2016,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2343,14 +2026,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2389,10 +2066,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2402,14 +2076,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2450,10 +2118,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2463,14 +2128,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2509,10 +2168,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2522,14 +2178,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2570,10 +2220,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2583,14 +2230,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2629,10 +2270,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2642,14 +2280,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2690,10 +2322,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2703,14 +2332,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2749,10 +2372,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2762,14 +2382,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2810,10 +2424,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2823,14 +2434,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2869,10 +2474,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2882,14 +2484,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2930,10 +2526,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -2943,14 +2536,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -2989,10 +2576,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -3002,14 +2586,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -3050,10 +2628,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -3063,14 +2638,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -3109,10 +2678,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -3122,14 +2688,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -3170,10 +2730,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -3183,14 +2740,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -3229,10 +2780,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -3242,14 +2790,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -3290,10 +2832,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -3303,14 +2842,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -3349,10 +2882,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -3362,14 +2892,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -3410,10 +2934,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -3423,14 +2944,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -3469,10 +2984,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -3482,14 +2994,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -3530,10 +3036,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -3543,14 +3046,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -3589,10 +3086,7 @@ describe('given the load organizations connection function', () => { const expectedStructure = { edges: [ { - cursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + cursor: toGlobalId('verifiedOrganization', expectedOrg._key), node: { ...expectedOrg, }, @@ -3602,14 +3096,8 @@ describe('given the load organizations connection function', () => { pageInfo: { hasNextPage: true, hasPreviousPage: true, - startCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), - endCursor: toGlobalId( - 'verifiedOrganization', - expectedOrg._key, - ), + startCursor: toGlobalId('verifiedOrganization', expectedOrg._key), + endCursor: toGlobalId('verifiedOrganization', expectedOrg._key), }, } @@ -3740,9 +3228,7 @@ describe('given the load organizations connection function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`first` on the `VerifiedOrganization` connection cannot be less than zero.', - ), + new Error('`first` on the `VerifiedOrganization` connection cannot be less than zero.'), ) } @@ -3769,9 +3255,7 @@ describe('given the load organizations connection function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`last` on the `VerifiedOrganization` connection cannot be less than zero.', - ), + new Error('`last` on the `VerifiedOrganization` connection cannot be less than zero.'), ) } @@ -3806,9 +3290,7 @@ describe('given the load organizations connection function', () => { ) } - expect(consoleOutput).toEqual([ - 'User attempted to have `first` to 101 for: loadVerifiedOrgConnections.', - ]) + expect(consoleOutput).toEqual(['User attempted to have `first` to 101 for: loadVerifiedOrgConnections.']) }) }) describe('last is set', () => { @@ -3835,18 +3317,14 @@ describe('given the load organizations connection function', () => { ) } - expect(consoleOutput).toEqual([ - 'User attempted to have `last` to 101 for: loadVerifiedOrgConnections.', - ]) + expect(consoleOutput).toEqual(['User attempted to have `last` to 101 for: loadVerifiedOrgConnections.']) }) }) }) describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadVerifiedOrgConnections({ query, language: 'en', @@ -3863,11 +3341,7 @@ describe('given the load organizations connection function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`first\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User attempted to have \`first\` set as a ${typeof invalidInput} for: loadVerifiedOrgConnections.`, @@ -3877,9 +3351,7 @@ describe('given the load organizations connection function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadVerifiedOrgConnections({ query, language: 'en', @@ -3896,11 +3368,7 @@ describe('given the load organizations connection function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - `\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`, - ), - ) + expect(err).toEqual(new Error(`\`last\` must be of type \`number\` not \`${typeof invalidInput}\`.`)) } expect(consoleOutput).toEqual([ `User attempted to have \`last\` set as a ${typeof invalidInput} for: loadVerifiedOrgConnections.`, @@ -3913,9 +3381,7 @@ describe('given the load organizations connection function', () => { describe('given a database error', () => { describe('when gathering organizations', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const query = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const connectionLoader = loadVerifiedOrgConnections({ query, @@ -3930,11 +3396,7 @@ describe('given the load organizations connection function', () => { } await connectionLoader({ ...connectionArgs }) } catch (err) { - expect(err).toEqual( - new Error( - 'Unable to load verified organization(s). Please try again.', - ), - ) + expect(err).toEqual(new Error('Unable to load verified organization(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -3967,11 +3429,7 @@ describe('given the load organizations connection function', () => { ...connectionArgs, }) } catch (err) { - expect(err).toEqual( - new Error( - 'Unable to load verified organization(s). Please try again.', - ), - ) + expect(err).toEqual(new Error('Unable to load verified organization(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -4070,9 +3528,7 @@ describe('given the load organizations connection function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`first` sur la connexion `VerifiedOrganization` ne peut être inférieur à zéro.', - ), + new Error('`first` sur la connexion `VerifiedOrganization` ne peut être inférieur à zéro.'), ) } @@ -4099,9 +3555,7 @@ describe('given the load organizations connection function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - '`last` sur la connexion `VerifiedOrganization` ne peut être inférieur à zéro.', - ), + new Error('`last` sur la connexion `VerifiedOrganization` ne peut être inférieur à zéro.'), ) } @@ -4136,9 +3590,7 @@ describe('given the load organizations connection function', () => { ) } - expect(consoleOutput).toEqual([ - 'User attempted to have `first` to 101 for: loadVerifiedOrgConnections.', - ]) + expect(consoleOutput).toEqual(['User attempted to have `first` to 101 for: loadVerifiedOrgConnections.']) }) }) describe('last is set', () => { @@ -4165,18 +3617,14 @@ describe('given the load organizations connection function', () => { ) } - expect(consoleOutput).toEqual([ - 'User attempted to have `last` to 101 for: loadVerifiedOrgConnections.', - ]) + expect(consoleOutput).toEqual(['User attempted to have `last` to 101 for: loadVerifiedOrgConnections.']) }) }) }) describe('limits are not set to numbers', () => { describe('first limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when first set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when first set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadVerifiedOrgConnections({ query, language: 'fr', @@ -4194,9 +3642,7 @@ describe('given the load organizations connection function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`first\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -4207,9 +3653,7 @@ describe('given the load organizations connection function', () => { }) describe('last limit is set', () => { ;['123', {}, [], null, true].forEach((invalidInput) => { - it(`returns an error when last set to ${stringify( - invalidInput, - )}`, async () => { + it(`returns an error when last set to ${stringify(invalidInput)}`, async () => { const connectionLoader = loadVerifiedOrgConnections({ query, language: 'fr', @@ -4227,9 +3671,7 @@ describe('given the load organizations connection function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - `\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`, - ), + new Error(`\`last\` doit être de type \`number\` et non \`${typeof invalidInput}\`.`), ) } expect(consoleOutput).toEqual([ @@ -4243,9 +3685,7 @@ describe('given the load organizations connection function', () => { describe('given a database error', () => { describe('when gathering organizations', () => { it('returns an error message', async () => { - const query = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const query = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const connectionLoader = loadVerifiedOrgConnections({ query, @@ -4260,11 +3700,7 @@ describe('given the load organizations connection function', () => { } await connectionLoader({ ...connectionArgs }) } catch (err) { - expect(err).toEqual( - new Error( - 'Impossible de charger le(s) organisme(s) vérifié(s). Veuillez réessayer.', - ), - ) + expect(err).toEqual(new Error('Impossible de charger le(s) organisme(s) vérifié(s). Veuillez réessayer.')) } expect(consoleOutput).toEqual([ @@ -4298,9 +3734,7 @@ describe('given the load organizations connection function', () => { }) } catch (err) { expect(err).toEqual( - new Error( - 'Impossible de charger le(s) organisme(s) vérifié(s). Veuillez réessayer.', - ), + new Error('Impossible de charger le(s) organisme(s) vérifié(s). Veuillez réessayer.'), ) } diff --git a/api/src/verified-organizations/loaders/__tests__/load-verified-organization-by-key.test.js b/api/src/verified-organizations/loaders/__tests__/load-verified-organization-by-key.test.js index fdd438d603..d4564b6ad5 100644 --- a/api/src/verified-organizations/loaders/__tests__/load-verified-organization-by-key.test.js +++ b/api/src/verified-organizations/loaders/__tests__/load-verified-organization-by-key.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' @@ -23,16 +24,16 @@ describe('given a loadVerifiedOrgByKey dataloader', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, - schema: dbschema, - })) + schema: dbschema, + })) }) beforeEach(async () => { await collections.organizations.save({ @@ -243,9 +244,7 @@ describe('given a loadVerifiedOrgByKey dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadVerifiedOrgByKey({ query: mockedQuery, language: 'en', @@ -255,11 +254,7 @@ describe('given a loadVerifiedOrgByKey dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error( - 'Unable to find verified organization(s). Please try again.', - ), - ) + expect(err).toEqual(new Error('Unable to find verified organization(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -284,11 +279,7 @@ describe('given a loadVerifiedOrgByKey dataloader', () => { try { await loader.load('1') } catch (err) { - expect(err).toEqual( - new Error( - 'Unable to find verified organization(s). Please try again.', - ), - ) + expect(err).toEqual(new Error('Unable to find verified organization(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -314,9 +305,7 @@ describe('given a loadVerifiedOrgByKey dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadVerifiedOrgByKey({ query: mockedQuery, language: 'fr', @@ -327,9 +316,7 @@ describe('given a loadVerifiedOrgByKey dataloader', () => { await loader.load('1') } catch (err) { expect(err).toEqual( - new Error( - 'Impossible de trouver une ou plusieurs organisations vérifiées. Veuillez réessayer.', - ), + new Error('Impossible de trouver une ou plusieurs organisations vérifiées. Veuillez réessayer.'), ) } @@ -356,9 +343,7 @@ describe('given a loadVerifiedOrgByKey dataloader', () => { await loader.load('1') } catch (err) { expect(err).toEqual( - new Error( - 'Impossible de trouver une ou plusieurs organisations vérifiées. Veuillez réessayer.', - ), + new Error('Impossible de trouver une ou plusieurs organisations vérifiées. Veuillez réessayer.'), ) } diff --git a/api/src/verified-organizations/loaders/__tests__/load-verified-organization-by-slug.test.js b/api/src/verified-organizations/loaders/__tests__/load-verified-organization-by-slug.test.js index e67fdbe77e..446f68518f 100644 --- a/api/src/verified-organizations/loaders/__tests__/load-verified-organization-by-slug.test.js +++ b/api/src/verified-organizations/loaders/__tests__/load-verified-organization-by-slug.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { setupI18n } from '@lingui/core' import englishMessages from '../../../locale/en/messages' @@ -23,16 +24,16 @@ describe('given a loadVerifiedOrgBySlug dataloader', () => { describe('given a successful load', () => { beforeAll(async () => { ;({ query, drop, truncate, collections } = await ensure({ - variables: { - dbname: dbNameFromFile(__filename), - username: 'root', - rootPassword: rootPass, - password: rootPass, - url, - }, + variables: { + dbname: dbNameFromFile(__filename), + username: 'root', + rootPassword: rootPass, + password: rootPass, + url, + }, - schema: dbschema, - })) + schema: dbschema, + })) }) beforeEach(async () => { await collections.organizations.save({ @@ -243,9 +244,7 @@ describe('given a loadVerifiedOrgBySlug dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadVerifiedOrgBySlug({ query: mockedQuery, language: 'en', @@ -255,11 +254,7 @@ describe('given a loadVerifiedOrgBySlug dataloader', () => { try { await loader.load('slug') } catch (err) { - expect(err).toEqual( - new Error( - 'Unable to find verified organization(s). Please try again.', - ), - ) + expect(err).toEqual(new Error('Unable to find verified organization(s). Please try again.')) } expect(consoleOutput).toEqual([ @@ -284,16 +279,10 @@ describe('given a loadVerifiedOrgBySlug dataloader', () => { try { await loader.load('slug') } catch (err) { - expect(err).toEqual( - new Error( - 'Unable to find verified organization(s). Please try again.', - ), - ) + expect(err).toEqual(new Error('Unable to find verified organization(s). Please try again.')) } - expect(consoleOutput).toEqual([ - `Cursor error during loadVerifiedOrgBySlug: Error: Cursor error occurred.`, - ]) + expect(consoleOutput).toEqual([`Cursor error during loadVerifiedOrgBySlug: Error: Cursor error occurred.`]) }) }) }) @@ -314,9 +303,7 @@ describe('given a loadVerifiedOrgBySlug dataloader', () => { }) describe('database error is raised', () => { it('returns an error', async () => { - const mockedQuery = jest - .fn() - .mockRejectedValue(new Error('Database error occurred.')) + const mockedQuery = jest.fn().mockRejectedValue(new Error('Database error occurred.')) const loader = loadVerifiedOrgBySlug({ query: mockedQuery, language: 'fr', @@ -327,9 +314,7 @@ describe('given a loadVerifiedOrgBySlug dataloader', () => { await loader.load('slug') } catch (err) { expect(err).toEqual( - new Error( - 'Impossible de trouver une ou plusieurs organisations vérifiées. Veuillez réessayer.', - ), + new Error('Impossible de trouver une ou plusieurs organisations vérifiées. Veuillez réessayer.'), ) } @@ -356,15 +341,11 @@ describe('given a loadVerifiedOrgBySlug dataloader', () => { await loader.load('slug') } catch (err) { expect(err).toEqual( - new Error( - 'Impossible de trouver une ou plusieurs organisations vérifiées. Veuillez réessayer.', - ), + new Error('Impossible de trouver une ou plusieurs organisations vérifiées. Veuillez réessayer.'), ) } - expect(consoleOutput).toEqual([ - `Cursor error during loadVerifiedOrgBySlug: Error: Cursor error occurred.`, - ]) + expect(consoleOutput).toEqual([`Cursor error during loadVerifiedOrgBySlug: Error: Cursor error occurred.`]) }) }) }) diff --git a/api/src/verified-organizations/queries/__tests__/find-verified-organization-by-slug.test.js b/api/src/verified-organizations/queries/__tests__/find-verified-organization-by-slug.test.js index 43e8c0f8d9..c994d08ea4 100644 --- a/api/src/verified-organizations/queries/__tests__/find-verified-organization-by-slug.test.js +++ b/api/src/verified-organizations/queries/__tests__/find-verified-organization-by-slug.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema, GraphQLError } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/verified-organizations/queries/__tests__/find-verified-organizations.test.js b/api/src/verified-organizations/queries/__tests__/find-verified-organizations.test.js index da498685b7..2b212ac3d8 100644 --- a/api/src/verified-organizations/queries/__tests__/find-verified-organizations.test.js +++ b/api/src/verified-organizations/queries/__tests__/find-verified-organizations.test.js @@ -1,4 +1,5 @@ -import { ensure, dbNameFromFile } from 'arango-tools' +import { dbNameFromFile } from 'arango-tools' +import { ensureDatabase as ensure } from '../../../testUtilities' import { graphql, GraphQLSchema } from 'graphql' import { toGlobalId } from 'graphql-relay' import { setupI18n } from '@lingui/core' diff --git a/api/src/web-scan/objects/tls-result.js b/api/src/web-scan/objects/tls-result.js index 40772d91bf..3ae6e5b1e0 100644 --- a/api/src/web-scan/objects/tls-result.js +++ b/api/src/web-scan/objects/tls-result.js @@ -53,22 +53,22 @@ export const tlsResultType = new GraphQLObjectType({ positiveTags: { type: new GraphQLList(guidanceTagType), description: `List of positive tags for the scanned server from this scan.`, - resolve: async ({ positiveTags }, _, { loaders: { loadSslGuidanceTagByTagId } }) => { - return await loadSslGuidanceTagByTagId({ tags: positiveTags }) + resolve: async ({ positiveTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: positiveTags }) }, }, neutralTags: { type: new GraphQLList(guidanceTagType), description: `List of neutral tags for the scanned server from this scan.`, - resolve: async ({ neutralTags }, _, { loaders: { loadSslGuidanceTagByTagId } }) => { - return await loadSslGuidanceTagByTagId({ tags: neutralTags }) + resolve: async ({ neutralTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: neutralTags }) }, }, negativeTags: { type: new GraphQLList(guidanceTagType), description: `List of negative tags for the scanned server from this scan.`, - resolve: async ({ negativeTags }, _, { loaders: { loadSslGuidanceTagByTagId } }) => { - return await loadSslGuidanceTagByTagId({ tags: negativeTags }) + resolve: async ({ negativeTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: negativeTags }) }, }, certificateStatus: { @@ -247,6 +247,10 @@ export const certificateChainInfoType = new GraphQLObjectType({ type: GraphQLBoolean, description: `Whether or not the certificate chain passed validation.`, }, + hasEntrustCertificate: { + type: GraphQLBoolean, + description: `Whether or not the certificate chain contains an Entrust certificate.`, + }, }), }) diff --git a/api/src/web-scan/objects/web-connection-result.js b/api/src/web-scan/objects/web-connection-result.js index 99f0ff2902..926e1452df 100644 --- a/api/src/web-scan/objects/web-connection-result.js +++ b/api/src/web-scan/objects/web-connection-result.js @@ -68,22 +68,22 @@ export const webConnectionResultType = new GraphQLObjectType({ positiveTags: { type: new GraphQLList(guidanceTagType), description: `List of positive tags for the scanned server from this scan.`, - resolve: async ({ positiveTags }, _, { loaders: { loadHttpsGuidanceTagByTagId } }) => { - return await loadHttpsGuidanceTagByTagId({ tags: positiveTags }) + resolve: async ({ positiveTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: positiveTags }) }, }, neutralTags: { type: new GraphQLList(guidanceTagType), description: `List of neutral tags for the scanned server from this scan.`, - resolve: async ({ neutralTags }, _, { loaders: { loadHttpsGuidanceTagByTagId } }) => { - return await loadHttpsGuidanceTagByTagId({ tags: neutralTags }) + resolve: async ({ neutralTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: neutralTags }) }, }, negativeTags: { type: new GraphQLList(guidanceTagType), description: `List of negative tags for the scanned server from this scan.`, - resolve: async ({ negativeTags }, _, { loaders: { loadHttpsGuidanceTagByTagId } }) => { - return await loadHttpsGuidanceTagByTagId({ tags: negativeTags }) + resolve: async ({ negativeTags }, _, { loaders: { loadGuidanceTagByTagId } }) => { + return await loadGuidanceTagByTagId({ tags: negativeTags }) }, }, }), diff --git a/api/test-docker-compose.yaml b/api/test-docker-compose.yaml index a5cb8757cb..91fa12779b 100644 --- a/api/test-docker-compose.yaml +++ b/api/test-docker-compose.yaml @@ -10,10 +10,11 @@ services: - "14222:4222" arangodb-test: - image: arangodb:3.10.5 + image: arangodb:3.12.1 container_name: arangodb-test environment: - ARANGO_ROOT_PASSWORD=test + restart: unless-stopped ports: - "18529:8529" diff --git a/azure-defender-easm/add-domain-to-easm/service.py b/azure-defender-easm/add-domain-to-easm/service.py index d3bc606b27..a31874cef1 100644 --- a/azure-defender-easm/add-domain-to-easm/service.py +++ b/azure-defender-easm/add-domain-to-easm/service.py @@ -1,54 +1,118 @@ import logging import os +from dataclasses import dataclass + from dotenv import load_dotenv import asyncio import nats -import functools import json import signal +from nats.errors import TimeoutError as NatsTimeoutError +from nats.js import JetStreamContext +from nats.js.api import RetentionPolicy, ConsumerConfig, AckPolicy + load_dotenv() logging.basicConfig( level=logging.INFO, format="[%(asctime)s :: %(name)s :: %(levelname)s] %(message)s" ) -logger = logging.getLogger() +logger = logging.getLogger(__name__) from clients.easm_client import run_disco_group, create_disco_group from clients.kusto_client import get_host_asset NAME = os.getenv("NAME", "add-domain-to-easm") -SUBSCRIBE_TO = os.getenv("SUBSCRIBE_TO", "domains.*.easm") -QUEUE_GROUP = os.getenv("QUEUE_GROUP", "add-domain-to-easm") SERVERLIST = os.getenv("NATS_SERVERS", "nats://localhost:4222") SERVERS = SERVERLIST.split(",") -async def run(loop): - async def error_cb(error): - logger.error(error) +async def run(): + loop = asyncio.get_running_loop() + + @dataclass + class Context: + should_exit: bool = False + sub: JetStreamContext.PullSubscription = None - async def closed_cb(): - logger.info("Connection to NATS is closed.") - await asyncio.sleep(0.1) - loop.stop() + context = Context() + + async def error_cb(error): + logger.error(f"Uncaught error in callback: {error}") async def reconnected_cb(): - logger.info(f"Connected to NATS at {nc.connected_url.netloc}...") + logger.info(f"Reconnected to NATS at {nc.connected_url.netloc}...") + # Ensure jetstream stream and consumer are still present + await js.add_stream(**add_stream_options) + context.sub = await js.pull_subscribe(**pull_subscribe_options) nc = await nats.connect( error_cb=error_cb, - closed_cb=closed_cb, reconnected_cb=reconnected_cb, servers=SERVERS, name=NAME, ) + js = nc.jetstream() logger.info(f"Connected to NATS at {nc.connected_url.netloc}...") - async def subscribe_handler(msg): - await asyncio.sleep(0.01) + add_stream_options = { + "name": "SCANS", + "subjects": [ + "scans.requests", + "scans.discovery", + "scans.add_domain_to_easm", + "scans.dns_scanner_results", + "scans.dns_processor_results", + "scans.web_scanner_results", + "scans.web_processor_results", + ], + "retention": RetentionPolicy.WORK_QUEUE, + } + + await js.add_stream(**add_stream_options) + + pull_subscribe_options = { + "stream": "SCANS", + "subject": "scans.add_domain_to_easm", + "durable": "add_domain_to_easm", + "config": ConsumerConfig( + ack_policy=AckPolicy.EXPLICIT, + max_deliver=1, + max_waiting=100_000, + ack_wait=90, + ), + } + + context.sub = await js.pull_subscribe(**pull_subscribe_options) + + async def ask_exit(sig_name): + if context.should_exit is True: + return + logger.error(f"Got signal {sig_name}: exit") + context.should_exit = True + + for signal_name in {"SIGINT", "SIGTERM"}: + loop.add_signal_handler( + getattr(signal, signal_name), + lambda: asyncio.create_task(ask_exit(signal_name)), + ) + + while True: + if context.should_exit: + break + if nc.is_closed: + logger.error("Connection to NATS is closed") + + try: + logger.debug("Fetching message...") + msgs = await context.sub.fetch(batch=1, timeout=1) + msg = msgs[0] + except NatsTimeoutError: + logger.debug("No messages available...") + continue + subject = msg.subject reply = msg.reply data = msg.data.decode() @@ -78,28 +142,6 @@ async def subscribe_handler(msg): logger.error(f"Scanning subdomains: {str(e)}") return - await nc.subscribe(subject=SUBSCRIBE_TO, queue=QUEUE_GROUP, cb=subscribe_handler) - - def ask_exit(sig_name): - logger.error(f"Got signal {sig_name}: exit") - if nc.is_closed: - return - loop.create_task(nc.close()) - - for signal_name in {"SIGINT", "SIGTERM"}: - loop.add_signal_handler( - getattr(signal, signal_name), functools.partial(ask_exit, signal_name) - ) - - -def main(): - loop = asyncio.new_event_loop() - loop.run_until_complete(run(loop)) - try: - loop.run_forever() - finally: - loop.close() - if __name__ == "__main__": - main() + asyncio.run(run()) diff --git a/azure-defender-easm/add-easm-assets-to-tracker/clients/kusto_client.py b/azure-defender-easm/add-easm-assets-to-tracker/clients/kusto_client.py index fe995568a3..fbfeabbf75 100644 --- a/azure-defender-easm/add-easm-assets-to-tracker/clients/kusto_client.py +++ b/azure-defender-easm/add-easm-assets-to-tracker/clients/kusto_client.py @@ -31,6 +31,10 @@ def get_labelled_org_assets_from_org_key(org_key): | where TimeGeneratedValue > ago(24h) | where AssetType == 'HOST' | where Labels == orgKey + | where AssetName !startswith '*.' + | join kind=inner EasmHostAsset on AssetName + | where TimeGeneratedValue > ago(24h) + | where Cnames == '[]' | project AssetName """ try: @@ -50,6 +54,11 @@ def get_unlabelled_assets(): | where TimeGeneratedValue > ago(24h) | where AssetType == 'HOST' | where Labels == '[]' + | where AssetName !startswith '*.' + | where AssetName endswith '.gc.ca' or AssetName endswith '.canada.ca' + | join kind=inner EasmHostAsset on AssetName + | where TimeGeneratedValue > ago(24h) + | where Cnames == '[]' | project AssetName """ try: diff --git a/azure-defender-easm/add-easm-assets-to-tracker/service.py b/azure-defender-easm/add-easm-assets-to-tracker/service.py index 985980e878..c132123a94 100644 --- a/azure-defender-easm/add-easm-assets-to-tracker/service.py +++ b/azure-defender-easm/add-easm-assets-to-tracker/service.py @@ -7,6 +7,7 @@ from dotenv import load_dotenv import asyncio import nats +from nats.js.api import RetentionPolicy load_dotenv() @@ -26,7 +27,6 @@ DB_URL = os.getenv("DB_URL") NATS_URL = os.getenv("NATS_URL") -PUBLISH_TO = os.getenv("PUBLISH_TO", "domains") UNCLAIMED_ID = os.getenv("UNCLAIMED_ID") # Establish DB connection @@ -35,14 +35,26 @@ async def main(): - # Connect to NATS logger.info("Connecting to NATS") nc = await nats.connect(NATS_URL) logger.info("Successfully connected to NATS") - # Create JetStream context. + js = nc.jetstream() - # Persist messages on 'foo's subject. - await js.add_stream(name="domains", subjects=[f"{PUBLISH_TO}.*"]) + add_stream_options = { + "name": "SCANS", + "subjects": [ + "scans.requests", + "scans.discovery", + "scans.add_domain_to_easm", + "scans.dns_scanner_results", + "scans.dns_processor_results", + "scans.web_scanner_results", + "scans.web_processor_results", + ], + "retention": RetentionPolicy.WORK_QUEUE, + } + + await js.add_stream(**add_stream_options) async def publish(channel, msg): await js.publish(channel, msg) @@ -59,7 +71,7 @@ def get_verified_orgs(): logger.info(f"Successfully fetched verified orgs") return [domain for domain in cursor] except Exception as e: - logger.error(f"Error occured when fetching verified orgs: {e}") + logger.error(f"Error occurred when fetching verified orgs: {e}") return [] def get_org_domains(org_id): @@ -120,7 +132,6 @@ def create_claim(org_id, domain_id, domain_name, txn_col): "_from": org_id, "_to": domain_id, "tags": [{"en": "NEW", "fr": "NOUVEAU"}], - "hidden": False, "outsideComment": "", "firstSeen": date.today().isoformat(), } @@ -135,9 +146,9 @@ def log_activity(domain, org_id, trx_col): insert_activity = { "timestamp": date.today().isoformat(), "initiatedBy": { - "id": "easm-service", - "userName": "easm-service", - "role": "easm-service", + "id": "easm", + "userName": "automated-discovery-service", + "role": "service", }, "target": { "resource": domain, @@ -211,7 +222,7 @@ async def add_discovered_domain(domains, org_id): # publish domain to NATS try: await publish( - f"{PUBLISH_TO}.{created_domain['_key']}", + "scans.requests", json.dumps( { "domain": created_domain["domain"], diff --git a/azure-defender-easm/import-easm-additional-findings/.env.example b/azure-defender-easm/import-easm-additional-findings/.env.example index 14f05533d6..bed1213e87 100644 --- a/azure-defender-easm/import-easm-additional-findings/.env.example +++ b/azure-defender-easm/import-easm-additional-findings/.env.example @@ -1,6 +1,7 @@ CLIENT_ID= CLIENT_SECRET= TENANT_ID= +CVE_LIST= KUSTO_CLUSTER= KUSTO_DATABASE= diff --git a/azure-defender-easm/import-easm-additional-findings/clients/kusto_client.py b/azure-defender-easm/import-easm-additional-findings/clients/kusto_client.py index 6d62ed1567..6343eaaa68 100644 --- a/azure-defender-easm/import-easm-additional-findings/clients/kusto_client.py +++ b/azure-defender-easm/import-easm-additional-findings/clients/kusto_client.py @@ -14,6 +14,7 @@ CLIENT_ID = os.getenv("CLIENT_ID") CLIENT_SECRET = os.getenv("CLIENT_SECRET") TENANT_ID = os.getenv("TENANT_ID") +CVE_LIST = os.getenv("CVE_LIST") KCSB_DATA = KustoConnectionStringBuilder.with_aad_application_key_authentication( f"https://{KUSTO_CLUSTER}.{REGION}.kusto.windows.net", @@ -39,9 +40,16 @@ def get_web_components_by_asset(asset): ) for wc in data: + # format datetime to isoformat wc["WebComponentFirstSeen"] = wc["WebComponentFirstSeen"].isoformat() wc["WebComponentLastSeen"] = wc["WebComponentLastSeen"].isoformat() + # filter cves to only top 25 + top25 = CVE_LIST.split(",") + wc["WebComponentCves"] = [ + cve for cve in wc["WebComponentCves"] if cve["Cve"] in top25 + ] + return data diff --git a/azure-defender-easm/import-easm-additional-findings/service.py b/azure-defender-easm/import-easm-additional-findings/service.py index d0c29be08d..429baad615 100644 --- a/azure-defender-easm/import-easm-additional-findings/service.py +++ b/azure-defender-easm/import-easm-additional-findings/service.py @@ -32,7 +32,7 @@ def get_all_domains(): FOR domain IN domains FILTER domain.archived != True FILTER domain.rcode != "NXDOMAIN" - RETURN { "domain": domain.domain, "id": domain._id } + RETURN { "domain": domain.domain, "id": domain._id, "key": domain._key } """ cursor = db.aql.execute(query) return [domain for domain in cursor] @@ -58,6 +58,19 @@ def remove_none_val_in_dict(dict): return new_dict +def update_domain_cve_detected(domain, web_components): + cve_detected = False + for wc in web_components: + if len(wc["WebComponentCves"]) > 0: + cve_detected = True + break + query = f""" + UPDATE {{ _key: "{domain["key"]}", cveDetected: {cve_detected} }} IN domains + """ + cursor = db.aql.execute(query) + return [domain for domain in cursor] + + def main(): try: domains = get_all_domains() @@ -89,6 +102,7 @@ def main(): # insert the findings into the DB logger.info(f"Upserting additional findings for domain {domain['domain']}") upsert_finding(insert_obj) + update_domain_cve_detected(domain, web_components) except Exception as e: logger.error(f"Failed to process domain {domain['domain']}: {e}") continue diff --git a/azure-defender-easm/label-known-easm-assets/service.py b/azure-defender-easm/label-known-easm-assets/service.py index a63bccfdee..ace819a99a 100644 --- a/azure-defender-easm/label-known-easm-assets/service.py +++ b/azure-defender-easm/label-known-easm-assets/service.py @@ -45,7 +45,6 @@ def get_verified_orgs(): def get_org_domains(org_id): query = f""" FOR v, e IN 1..1 OUTBOUND @org_id claims - FILTER e.hidden != true FILTER v.archived != true FILTER v.rcode != "NXDOMAIN" RETURN v.domain diff --git a/clients/python/Pipfile b/clients/python/Pipfile index 820fc20907..0a877d25d9 100644 --- a/clients/python/Pipfile +++ b/clients/python/Pipfile @@ -5,10 +5,10 @@ name = "pypi" [packages] gql = ">=3.0.0a5" -aiohttp = "==3.9.5" +aiohttp = "==3.10.2" websockets = "*" python-slugify = "*" -cryptography = "~=42.0.0" +cryptography = "~=43.0.1" [dev-packages] black = "*" diff --git a/clients/python/Pipfile.lock b/clients/python/Pipfile.lock index 6e00acc8a9..adefdb054f 100644 --- a/clients/python/Pipfile.lock +++ b/clients/python/Pipfile.lock @@ -1,7 +1,7 @@ { "_meta": { "hash": { - "sha256": "abb790ec24b9f0c1d1a0df03a4156ecbcc3151d416a18fb39ffafd02f00f23c5" + "sha256": "d5c1448cb2a7a481282b350a402b2507fe2b3abae8cb7fe40809401fde25d9be" }, "pipfile-spec": 6, "requires": {}, @@ -14,88 +14,96 @@ ] }, "default": { + "aiohappyeyeballs": { + "hashes": [ + "sha256:4d6dea59215537dbc746e93e779caea8178c866856a721c9c660d7a5a7b8be03", + "sha256:6fa48b9f1317254f122a07a131a86b71ca6946ca989ce6326fff54a99a920105" + ], + "markers": "python_version >= '3.8'", + "version": "==2.3.5" + }, "aiohttp": { "hashes": [ - "sha256:0605cc2c0088fcaae79f01c913a38611ad09ba68ff482402d3410bf59039bfb8", - "sha256:0a158704edf0abcac8ac371fbb54044f3270bdbc93e254a82b6c82be1ef08f3c", - "sha256:0cbf56238f4bbf49dab8c2dc2e6b1b68502b1e88d335bea59b3f5b9f4c001475", - "sha256:1732102949ff6087589408d76cd6dea656b93c896b011ecafff418c9661dc4ed", - "sha256:18f634d540dd099c262e9f887c8bbacc959847cfe5da7a0e2e1cf3f14dbf2daf", - "sha256:239f975589a944eeb1bad26b8b140a59a3a320067fb3cd10b75c3092405a1372", - "sha256:2faa61a904b83142747fc6a6d7ad8fccff898c849123030f8e75d5d967fd4a81", - "sha256:320e8618eda64e19d11bdb3bd04ccc0a816c17eaecb7e4945d01deee2a22f95f", - "sha256:38d80498e2e169bc61418ff36170e0aad0cd268da8b38a17c4cf29d254a8b3f1", - "sha256:3916c8692dbd9d55c523374a3b8213e628424d19116ac4308e434dbf6d95bbdd", - "sha256:393c7aba2b55559ef7ab791c94b44f7482a07bf7640d17b341b79081f5e5cd1a", - "sha256:3b7b30258348082826d274504fbc7c849959f1989d86c29bc355107accec6cfb", - "sha256:3fcb4046d2904378e3aeea1df51f697b0467f2aac55d232c87ba162709478c46", - "sha256:4109adee842b90671f1b689901b948f347325045c15f46b39797ae1bf17019de", - "sha256:4558e5012ee03d2638c681e156461d37b7a113fe13970d438d95d10173d25f78", - "sha256:45731330e754f5811c314901cebdf19dd776a44b31927fa4b4dbecab9e457b0c", - "sha256:4715a9b778f4293b9f8ae7a0a7cef9829f02ff8d6277a39d7f40565c737d3771", - "sha256:471f0ef53ccedec9995287f02caf0c068732f026455f07db3f01a46e49d76bbb", - "sha256:4d3ebb9e1316ec74277d19c5f482f98cc65a73ccd5430540d6d11682cd857430", - "sha256:4ff550491f5492ab5ed3533e76b8567f4b37bd2995e780a1f46bca2024223233", - "sha256:52c27110f3862a1afbcb2af4281fc9fdc40327fa286c4625dfee247c3ba90156", - "sha256:55b39c8684a46e56ef8c8d24faf02de4a2b2ac60d26cee93bc595651ff545de9", - "sha256:5a7ee16aab26e76add4afc45e8f8206c95d1d75540f1039b84a03c3b3800dd59", - "sha256:5ca51eadbd67045396bc92a4345d1790b7301c14d1848feaac1d6a6c9289e888", - "sha256:5d6b3f1fabe465e819aed2c421a6743d8debbde79b6a8600739300630a01bf2c", - "sha256:60cdbd56f4cad9f69c35eaac0fbbdf1f77b0ff9456cebd4902f3dd1cf096464c", - "sha256:6380c039ec52866c06d69b5c7aad5478b24ed11696f0e72f6b807cfb261453da", - "sha256:639d0042b7670222f33b0028de6b4e2fad6451462ce7df2af8aee37dcac55424", - "sha256:66331d00fb28dc90aa606d9a54304af76b335ae204d1836f65797d6fe27f1ca2", - "sha256:67c3119f5ddc7261d47163ed86d760ddf0e625cd6246b4ed852e82159617b5fb", - "sha256:694d828b5c41255e54bc2dddb51a9f5150b4eefa9886e38b52605a05d96566e8", - "sha256:6ae79c1bc12c34082d92bf9422764f799aee4746fd7a392db46b7fd357d4a17a", - "sha256:702e2c7c187c1a498a4e2b03155d52658fdd6fda882d3d7fbb891a5cf108bb10", - "sha256:714d4e5231fed4ba2762ed489b4aec07b2b9953cf4ee31e9871caac895a839c0", - "sha256:7b179eea70833c8dee51ec42f3b4097bd6370892fa93f510f76762105568cf09", - "sha256:7f64cbd44443e80094309875d4f9c71d0401e966d191c3d469cde4642bc2e031", - "sha256:82a6a97d9771cb48ae16979c3a3a9a18b600a8505b1115cfe354dfb2054468b4", - "sha256:84dabd95154f43a2ea80deffec9cb44d2e301e38a0c9d331cc4aa0166fe28ae3", - "sha256:8676e8fd73141ded15ea586de0b7cda1542960a7b9ad89b2b06428e97125d4fa", - "sha256:88e311d98cc0bf45b62fc46c66753a83445f5ab20038bcc1b8a1cc05666f428a", - "sha256:8b4f72fbb66279624bfe83fd5eb6aea0022dad8eec62b71e7bf63ee1caadeafe", - "sha256:8c64a6dc3fe5db7b1b4d2b5cb84c4f677768bdc340611eca673afb7cf416ef5a", - "sha256:8cf142aa6c1a751fcb364158fd710b8a9be874b81889c2bd13aa8893197455e2", - "sha256:8d1964eb7617907c792ca00b341b5ec3e01ae8c280825deadbbd678447b127e1", - "sha256:93e22add827447d2e26d67c9ac0161756007f152fdc5210277d00a85f6c92323", - "sha256:9c69e77370cce2d6df5d12b4e12bdcca60c47ba13d1cbbc8645dd005a20b738b", - "sha256:9dbc053ac75ccc63dc3a3cc547b98c7258ec35a215a92bd9f983e0aac95d3d5b", - "sha256:9e3a1ae66e3d0c17cf65c08968a5ee3180c5a95920ec2731f53343fac9bad106", - "sha256:a6ea1a5b409a85477fd8e5ee6ad8f0e40bf2844c270955e09360418cfd09abac", - "sha256:a81b1143d42b66ffc40a441379387076243ef7b51019204fd3ec36b9f69e77d6", - "sha256:ad7f2919d7dac062f24d6f5fe95d401597fbb015a25771f85e692d043c9d7832", - "sha256:afc52b8d969eff14e069a710057d15ab9ac17cd4b6753042c407dcea0e40bf75", - "sha256:b3df71da99c98534be076196791adca8819761f0bf6e08e07fd7da25127150d6", - "sha256:c088c4d70d21f8ca5c0b8b5403fe84a7bc8e024161febdd4ef04575ef35d474d", - "sha256:c26959ca7b75ff768e2776d8055bf9582a6267e24556bb7f7bd29e677932be72", - "sha256:c413016880e03e69d166efb5a1a95d40f83d5a3a648d16486592c49ffb76d0db", - "sha256:c6021d296318cb6f9414b48e6a439a7f5d1f665464da507e8ff640848ee2a58a", - "sha256:c671dc117c2c21a1ca10c116cfcd6e3e44da7fcde37bf83b2be485ab377b25da", - "sha256:c7a4b7a6cf5b6eb11e109a9755fd4fda7d57395f8c575e166d363b9fc3ec4678", - "sha256:c8a02fbeca6f63cb1f0475c799679057fc9268b77075ab7cf3f1c600e81dd46b", - "sha256:cd2adf5c87ff6d8b277814a28a535b59e20bfea40a101db6b3bdca7e9926bc24", - "sha256:d1469f228cd9ffddd396d9948b8c9cd8022b6d1bf1e40c6f25b0fb90b4f893ed", - "sha256:d153f652a687a8e95ad367a86a61e8d53d528b0530ef382ec5aaf533140ed00f", - "sha256:d5ab8e1f6bee051a4bf6195e38a5c13e5e161cb7bad83d8854524798bd9fcd6e", - "sha256:da00da442a0e31f1c69d26d224e1efd3a1ca5bcbf210978a2ca7426dfcae9f58", - "sha256:da22dab31d7180f8c3ac7c7635f3bcd53808f374f6aa333fe0b0b9e14b01f91a", - "sha256:e0ae53e33ee7476dd3d1132f932eeb39bf6125083820049d06edcdca4381f342", - "sha256:e7a6a8354f1b62e15d48e04350f13e726fa08b62c3d7b8401c0a1314f02e3558", - "sha256:e9a3d838441bebcf5cf442700e3963f58b5c33f015341f9ea86dcd7d503c07e2", - "sha256:edea7d15772ceeb29db4aff55e482d4bcfb6ae160ce144f2682de02f6d693551", - "sha256:f22eb3a6c1080d862befa0a89c380b4dafce29dc6cd56083f630073d102eb595", - "sha256:f26383adb94da5e7fb388d441bf09c61e5e35f455a3217bfd790c6b6bc64b2ee", - "sha256:f3c2890ca8c59ee683fd09adf32321a40fe1cf164e3387799efb2acebf090c11", - "sha256:f64fd07515dad67f24b6ea4a66ae2876c01031de91c93075b8093f07c0a2d93d", - "sha256:fcde4c397f673fdec23e6b05ebf8d4751314fa7c24f93334bf1f1364c1c69ac7", - "sha256:ff84aeb864e0fac81f676be9f4685f0527b660f1efdc40dcede3c251ef1e867f" + "sha256:01c98041f90927c2cbd72c22a164bb816fa3010a047d264969cf82e1d4bcf8d1", + "sha256:0df930015db36b460aa9badbf35eccbc383f00d52d4b6f3de2ccb57d064a6ade", + "sha256:1238fc979160bc03a92fff9ad021375ff1c8799c6aacb0d8ea1b357ea40932bb", + "sha256:14dc3fcb0d877911d775d511eb617a486a8c48afca0a887276e63db04d3ee920", + "sha256:14eb6b17f6246959fb0b035d4f4ae52caa870c4edfb6170aad14c0de5bfbf478", + "sha256:18186a80ec5a701816adbf1d779926e1069392cf18504528d6e52e14b5920525", + "sha256:19073d57d0feb1865d12361e2a1f5a49cb764bf81a4024a3b608ab521568093a", + "sha256:1aa005f060aff7124cfadaa2493f00a4e28ed41b232add5869e129a2e395935a", + "sha256:2c474af073e1a6763e1c5522bbb2d85ff8318197e4c6c919b8d7886e16213345", + "sha256:30a9d59da1543a6f1478c3436fd49ec59be3868bca561a33778b4391005e499d", + "sha256:341f8ece0276a828d95b70cd265d20e257f5132b46bf77d759d7f4e0443f2906", + "sha256:352f3a4e5f11f3241a49b6a48bc5b935fabc35d1165fa0d87f3ca99c1fcca98b", + "sha256:377220a5efde6f9497c5b74649b8c261d3cce8a84cb661be2ed8099a2196400a", + "sha256:3988044d1635c7821dd44f0edfbe47e9875427464e59d548aece447f8c22800a", + "sha256:465e445ec348d4e4bd349edd8b22db75f025da9d7b6dc1369c48e7935b85581e", + "sha256:494a6f77560e02bd7d1ab579fdf8192390567fc96a603f21370f6e63690b7f3d", + "sha256:49904f38667c44c041a0b44c474b3ae36948d16a0398a8f8cd84e2bb3c42a069", + "sha256:4d1f694b5d6e459352e5e925a42e05bac66655bfde44d81c59992463d2897014", + "sha256:4ddb43d06ce786221c0dfd3c91b4892c318eaa36b903f7c4278e7e2fa0dd5102", + "sha256:518dc3cb37365255708283d1c1c54485bbacccd84f0a0fb87ed8917ba45eda5b", + "sha256:53e8898adda402be03ff164b0878abe2d884e3ea03a4701e6ad55399d84b92dc", + "sha256:54ba10eb5a3481c28282eb6afb5f709aedf53cf9c3a31875ffbdc9fc719ffd67", + "sha256:54e36c67e1a9273ecafab18d6693da0fb5ac48fd48417e4548ac24a918c20998", + "sha256:562b1153ab7f766ee6b8b357ec777a302770ad017cf18505d34f1c088fccc448", + "sha256:5a7ceb2a0d2280f23a02c64cd0afdc922079bb950400c3dd13a1ab2988428aac", + "sha256:655e583afc639bef06f3b2446972c1726007a21003cd0ef57116a123e44601bc", + "sha256:685c1508ec97b2cd3e120bfe309a4ff8e852e8a7460f1ef1de00c2c0ed01e33c", + "sha256:686c87782481fda5ee6ba572d912a5c26d9f98cc5c243ebd03f95222af3f1b0f", + "sha256:69d73f869cf29e8a373127fc378014e2b17bcfbe8d89134bc6fb06a2f67f3cb3", + "sha256:6fe8503b1b917508cc68bf44dae28823ac05e9f091021e0c41f806ebbb23f92f", + "sha256:74c091a5ded6cb81785de2d7a8ab703731f26de910dbe0f3934eabef4ae417cc", + "sha256:7cc8f65f5b22304693de05a245b6736b14cb5bc9c8a03da6e2ae9ef15f8b458f", + "sha256:7dd9c7db94b4692b827ce51dcee597d61a0e4f4661162424faf65106775b40e7", + "sha256:7de3ddb6f424af54535424082a1b5d1ae8caf8256ebd445be68c31c662354720", + "sha256:7f98e70bbbf693086efe4b86d381efad8edac040b8ad02821453083d15ec315f", + "sha256:87fab7f948e407444c2f57088286e00e2ed0003ceaf3d8f8cc0f60544ba61d91", + "sha256:8bd7be6ff6c162a60cb8fce65ee879a684fbb63d5466aba3fa5b9288eb04aefa", + "sha256:8da9449a575133828cc99985536552ea2dcd690e848f9d41b48d8853a149a959", + "sha256:91b10208b222ddf655c3a3d5b727879d7163db12b634492df41a9182a76edaae", + "sha256:92f7f4a4dc9cdb5980973a74d43cdbb16286dacf8d1896b6c3023b8ba8436f8e", + "sha256:9360e3ffc7b23565600e729e8c639c3c50d5520e05fdf94aa2bd859eef12c407", + "sha256:947847f07a8f81d7b39b2d0202fd73e61962ebe17ac2d8566f260679e467da7b", + "sha256:95213b3d79c7e387144e9cb7b9d2809092d6ff2c044cb59033aedc612f38fb6d", + "sha256:96e010736fc16d21125c7e2dc5c350cd43c528b85085c04bf73a77be328fe944", + "sha256:99f81f9c1529fd8e03be4a7bd7df32d14b4f856e90ef6e9cbad3415dbfa9166c", + "sha256:9bb2834a6f11d65374ce97d366d6311a9155ef92c4f0cee543b2155d06dc921f", + "sha256:9dfc906d656e14004c5bc672399c1cccc10db38df2b62a13fb2b6e165a81c316", + "sha256:9f6f0b252a009e98fe84028a4ec48396a948e7a65b8be06ccfc6ef68cf1f614d", + "sha256:9fd16b5e1a7bdd14668cd6bde60a2a29b49147a535c74f50d8177d11b38433a7", + "sha256:a0fde16d284efcacbe15fb0c1013f0967b6c3e379649239d783868230bf1db42", + "sha256:a1a50e59b720060c29e2951fd9f13c01e1ea9492e5a527b92cfe04dd64453c16", + "sha256:a4be88807283bd96ae7b8e401abde4ca0bab597ba73b5e9a2d98f36d451e9aac", + "sha256:ad2274e707be37420d0b6c3d26a8115295fe9d8e6e530fa6a42487a8ca3ad052", + "sha256:b2bfdda4971bd79201f59adbad24ec2728875237e1c83bba5221284dbbf57bda", + "sha256:b52a27a5c97275e254704e1049f4b96a81e67d6205f52fa37a4777d55b0e98ef", + "sha256:c01fbb87b5426381cd9418b3ddcf4fc107e296fa2d3446c18ce6c76642f340a3", + "sha256:c836bf3c7512100219fe1123743fd8dd9a2b50dd7cfb0c3bb10d041309acab4b", + "sha256:c8e98e1845805f184d91fda6f9ab93d7c7b0dddf1c07e0255924bfdb151a8d05", + "sha256:ca2f5abcb0a9a47e56bac173c01e9f6c6e7f27534d91451c5f22e6a35a5a2093", + "sha256:cd33d9de8cfd006a0d0fe85f49b4183c57e91d18ffb7e9004ce855e81928f704", + "sha256:d611d1a01c25277bcdea06879afbc11472e33ce842322496b211319aa95441bb", + "sha256:d9076810a5621236e29b2204e67a68e1fe317c8727ee4c9abbfbb1083b442c38", + "sha256:d984db6d855de58e0fde1ef908d48fe9a634cadb3cf715962722b4da1c40619d", + "sha256:dafb4abb257c0ed56dc36f4e928a7341b34b1379bd87e5a15ce5d883c2c90574", + "sha256:ddfd2dca3f11c365d6857a07e7d12985afc59798458a2fdb2ffa4a0332a3fd43", + "sha256:df59f8486507c421c0620a2c3dce81fbf1d54018dc20ff4fecdb2c106d6e6abc", + "sha256:e00191d38156e09e8c81ef3d75c0d70d4f209b8381e71622165f22ef7da6f101", + "sha256:e2f43d238eae4f0b04f58d4c0df4615697d4ca3e9f9b1963d49555a94f0f5a04", + "sha256:e57e21e1167705f8482ca29cc5d02702208d8bf4aff58f766d94bcd6ead838cd", + "sha256:e8f515d6859e673940e08de3922b9c4a2249653b0ac181169313bd6e4b1978ac", + "sha256:eabe6bf4c199687592f5de4ccd383945f485779c7ffb62a9b9f1f8a3f9756df8", + "sha256:ec6ad66ed660d46503243cbec7b2b3d8ddfa020f984209b3b8ef7d98ce69c3f2", + "sha256:f81cd85a0e76ec7b8e2b6636fe02952d35befda4196b8c88f3cec5b4fb512839", + "sha256:f9f49bdb94809ac56e09a310a62f33e5f22973d6fd351aac72a39cd551e98194", + "sha256:fae962b62944eaebff4f4fddcf1a69de919e7b967136a318533d82d93c3c6bd1", + "sha256:fc61f39b534c5d5903490478a0dd349df397d2284a939aa3cbaa2fb7a19b8397" ], "index": "pypi", "markers": "python_version >= '3.8'", - "version": "==3.9.5" + "version": "==3.10.2" }, "aiosignal": { "hashes": [ @@ -123,11 +131,11 @@ }, "attrs": { "hashes": [ - "sha256:935dc3b529c262f6cf76e50877d35a4bd3c1de194fd41f47a2b7ae8f19971f30", - "sha256:99b87a485a5820b23b879f04c2305b44b951b502fd64be915879d77a7e8fc6f1" + "sha256:5cfb1b9148b5b086569baec03f20d7b6bf3bcacc9a42bebf87ffaaca362f6346", + "sha256:81921eb96de3191c8258c199618104dd27ac608d9366f5e35d011eae1867ede2" ], "markers": "python_version >= '3.7'", - "version": "==23.2.0" + "version": "==24.2.0" }, "backoff": { "hashes": [ @@ -139,100 +147,110 @@ }, "cffi": { "hashes": [ - "sha256:0c9ef6ff37e974b73c25eecc13952c55bceed9112be2d9d938ded8e856138bcc", - "sha256:131fd094d1065b19540c3d72594260f118b231090295d8c34e19a7bbcf2e860a", - "sha256:1b8ebc27c014c59692bb2664c7d13ce7a6e9a629be20e54e7271fa696ff2b417", - "sha256:2c56b361916f390cd758a57f2e16233eb4f64bcbeee88a4881ea90fca14dc6ab", - "sha256:2d92b25dbf6cae33f65005baf472d2c245c050b1ce709cc4588cdcdd5495b520", - "sha256:31d13b0f99e0836b7ff893d37af07366ebc90b678b6664c955b54561fc36ef36", - "sha256:32c68ef735dbe5857c810328cb2481e24722a59a2003018885514d4c09af9743", - "sha256:3686dffb02459559c74dd3d81748269ffb0eb027c39a6fc99502de37d501faa8", - "sha256:582215a0e9adbe0e379761260553ba11c58943e4bbe9c36430c4ca6ac74b15ed", - "sha256:5b50bf3f55561dac5438f8e70bfcdfd74543fd60df5fa5f62d94e5867deca684", - "sha256:5bf44d66cdf9e893637896c7faa22298baebcd18d1ddb6d2626a6e39793a1d56", - "sha256:6602bc8dc6f3a9e02b6c22c4fc1e47aa50f8f8e6d3f78a5e16ac33ef5fefa324", - "sha256:673739cb539f8cdaa07d92d02efa93c9ccf87e345b9a0b556e3ecc666718468d", - "sha256:68678abf380b42ce21a5f2abde8efee05c114c2fdb2e9eef2efdb0257fba1235", - "sha256:68e7c44931cc171c54ccb702482e9fc723192e88d25a0e133edd7aff8fcd1f6e", - "sha256:6b3d6606d369fc1da4fd8c357d026317fbb9c9b75d36dc16e90e84c26854b088", - "sha256:748dcd1e3d3d7cd5443ef03ce8685043294ad6bd7c02a38d1bd367cfd968e000", - "sha256:7651c50c8c5ef7bdb41108b7b8c5a83013bfaa8a935590c5d74627c047a583c7", - "sha256:7b78010e7b97fef4bee1e896df8a4bbb6712b7f05b7ef630f9d1da00f6444d2e", - "sha256:7e61e3e4fa664a8588aa25c883eab612a188c725755afff6289454d6362b9673", - "sha256:80876338e19c951fdfed6198e70bc88f1c9758b94578d5a7c4c91a87af3cf31c", - "sha256:8895613bcc094d4a1b2dbe179d88d7fb4a15cee43c052e8885783fac397d91fe", - "sha256:88e2b3c14bdb32e440be531ade29d3c50a1a59cd4e51b1dd8b0865c54ea5d2e2", - "sha256:8f8e709127c6c77446a8c0a8c8bf3c8ee706a06cd44b1e827c3e6a2ee6b8c098", - "sha256:9cb4a35b3642fc5c005a6755a5d17c6c8b6bcb6981baf81cea8bfbc8903e8ba8", - "sha256:9f90389693731ff1f659e55c7d1640e2ec43ff725cc61b04b2f9c6d8d017df6a", - "sha256:a09582f178759ee8128d9270cd1344154fd473bb77d94ce0aeb2a93ebf0feaf0", - "sha256:a6a14b17d7e17fa0d207ac08642c8820f84f25ce17a442fd15e27ea18d67c59b", - "sha256:a72e8961a86d19bdb45851d8f1f08b041ea37d2bd8d4fd19903bc3083d80c896", - "sha256:abd808f9c129ba2beda4cfc53bde801e5bcf9d6e0f22f095e45327c038bfe68e", - "sha256:ac0f5edd2360eea2f1daa9e26a41db02dd4b0451b48f7c318e217ee092a213e9", - "sha256:b29ebffcf550f9da55bec9e02ad430c992a87e5f512cd63388abb76f1036d8d2", - "sha256:b2ca4e77f9f47c55c194982e10f058db063937845bb2b7a86c84a6cfe0aefa8b", - "sha256:b7be2d771cdba2942e13215c4e340bfd76398e9227ad10402a8767ab1865d2e6", - "sha256:b84834d0cf97e7d27dd5b7f3aca7b6e9263c56308ab9dc8aae9784abb774d404", - "sha256:b86851a328eedc692acf81fb05444bdf1891747c25af7529e39ddafaf68a4f3f", - "sha256:bcb3ef43e58665bbda2fb198698fcae6776483e0c4a631aa5647806c25e02cc0", - "sha256:c0f31130ebc2d37cdd8e44605fb5fa7ad59049298b3f745c74fa74c62fbfcfc4", - "sha256:c6a164aa47843fb1b01e941d385aab7215563bb8816d80ff3a363a9f8448a8dc", - "sha256:d8a9d3ebe49f084ad71f9269834ceccbf398253c9fac910c4fd7053ff1386936", - "sha256:db8e577c19c0fda0beb7e0d4e09e0ba74b1e4c092e0e40bfa12fe05b6f6d75ba", - "sha256:dc9b18bf40cc75f66f40a7379f6a9513244fe33c0e8aa72e2d56b0196a7ef872", - "sha256:e09f3ff613345df5e8c3667da1d918f9149bd623cd9070c983c013792a9a62eb", - "sha256:e4108df7fe9b707191e55f33efbcb2d81928e10cea45527879a4749cbe472614", - "sha256:e6024675e67af929088fda399b2094574609396b1decb609c55fa58b028a32a1", - "sha256:e70f54f1796669ef691ca07d046cd81a29cb4deb1e5f942003f401c0c4a2695d", - "sha256:e715596e683d2ce000574bae5d07bd522c781a822866c20495e52520564f0969", - "sha256:e760191dd42581e023a68b758769e2da259b5d52e3103c6060ddc02c9edb8d7b", - "sha256:ed86a35631f7bfbb28e108dd96773b9d5a6ce4811cf6ea468bb6a359b256b1e4", - "sha256:ee07e47c12890ef248766a6e55bd38ebfb2bb8edd4142d56db91b21ea68b7627", - "sha256:fa3a0128b152627161ce47201262d3140edb5a5c3da88d73a1b790a959126956", - "sha256:fcc8eb6d5902bb1cf6dc4f187ee3ea80a1eba0a89aba40a5cb20a5087d961357" + "sha256:011aff3524d578a9412c8b3cfaa50f2c0bd78e03eb7af7aa5e0df59b158efb2f", + "sha256:0a048d4f6630113e54bb4b77e315e1ba32a5a31512c31a273807d0027a7e69ab", + "sha256:0bb15e7acf8ab35ca8b24b90af52c8b391690ef5c4aec3d31f38f0d37d2cc499", + "sha256:0d46ee4764b88b91f16661a8befc6bfb24806d885e27436fdc292ed7e6f6d058", + "sha256:0e60821d312f99d3e1569202518dddf10ae547e799d75aef3bca3a2d9e8ee693", + "sha256:0fdacad9e0d9fc23e519efd5ea24a70348305e8d7d85ecbb1a5fa66dc834e7fb", + "sha256:14b9cbc8f7ac98a739558eb86fabc283d4d564dafed50216e7f7ee62d0d25377", + "sha256:17c6d6d3260c7f2d94f657e6872591fe8733872a86ed1345bda872cfc8c74885", + "sha256:1a2ddbac59dc3716bc79f27906c010406155031a1c801410f1bafff17ea304d2", + "sha256:2404f3de742f47cb62d023f0ba7c5a916c9c653d5b368cc966382ae4e57da401", + "sha256:24658baf6224d8f280e827f0a50c46ad819ec8ba380a42448e24459daf809cf4", + "sha256:24aa705a5f5bd3a8bcfa4d123f03413de5d86e497435693b638cbffb7d5d8a1b", + "sha256:2770bb0d5e3cc0e31e7318db06efcbcdb7b31bcb1a70086d3177692a02256f59", + "sha256:331ad15c39c9fe9186ceaf87203a9ecf5ae0ba2538c9e898e3a6967e8ad3db6f", + "sha256:3aa9d43b02a0c681f0bfbc12d476d47b2b2b6a3f9287f11ee42989a268a1833c", + "sha256:41f4915e09218744d8bae14759f983e466ab69b178de38066f7579892ff2a555", + "sha256:4304d4416ff032ed50ad6bb87416d802e67139e31c0bde4628f36a47a3164bfa", + "sha256:435a22d00ec7d7ea533db494da8581b05977f9c37338c80bc86314bec2619424", + "sha256:45f7cd36186db767d803b1473b3c659d57a23b5fa491ad83c6d40f2af58e4dbb", + "sha256:48b389b1fd5144603d61d752afd7167dfd205973a43151ae5045b35793232aa2", + "sha256:4e67d26532bfd8b7f7c05d5a766d6f437b362c1bf203a3a5ce3593a645e870b8", + "sha256:516a405f174fd3b88829eabfe4bb296ac602d6a0f68e0d64d5ac9456194a5b7e", + "sha256:5ba5c243f4004c750836f81606a9fcb7841f8874ad8f3bf204ff5e56332b72b9", + "sha256:5bdc0f1f610d067c70aa3737ed06e2726fd9d6f7bfee4a351f4c40b6831f4e82", + "sha256:6107e445faf057c118d5050560695e46d272e5301feffda3c41849641222a828", + "sha256:6327b572f5770293fc062a7ec04160e89741e8552bf1c358d1a23eba68166759", + "sha256:669b29a9eca6146465cc574659058ed949748f0809a2582d1f1a324eb91054dc", + "sha256:6ce01337d23884b21c03869d2f68c5523d43174d4fc405490eb0091057943118", + "sha256:6d872186c1617d143969defeadac5a904e6e374183e07977eedef9c07c8953bf", + "sha256:6f76a90c345796c01d85e6332e81cab6d70de83b829cf1d9762d0a3da59c7932", + "sha256:70d2aa9fb00cf52034feac4b913181a6e10356019b18ef89bc7c12a283bf5f5a", + "sha256:7cbc78dc018596315d4e7841c8c3a7ae31cc4d638c9b627f87d52e8abaaf2d29", + "sha256:856bf0924d24e7f93b8aee12a3a1095c34085600aa805693fb7f5d1962393206", + "sha256:8a98748ed1a1df4ee1d6f927e151ed6c1a09d5ec21684de879c7ea6aa96f58f2", + "sha256:93a7350f6706b31f457c1457d3a3259ff9071a66f312ae64dc024f049055f72c", + "sha256:964823b2fc77b55355999ade496c54dde161c621cb1f6eac61dc30ed1b63cd4c", + "sha256:a003ac9edc22d99ae1286b0875c460351f4e101f8c9d9d2576e78d7e048f64e0", + "sha256:a0ce71725cacc9ebf839630772b07eeec220cbb5f03be1399e0457a1464f8e1a", + "sha256:a47eef975d2b8b721775a0fa286f50eab535b9d56c70a6e62842134cf7841195", + "sha256:a8b5b9712783415695663bd463990e2f00c6750562e6ad1d28e072a611c5f2a6", + "sha256:a9015f5b8af1bb6837a3fcb0cdf3b874fe3385ff6274e8b7925d81ccaec3c5c9", + "sha256:aec510255ce690d240f7cb23d7114f6b351c733a74c279a84def763660a2c3bc", + "sha256:b00e7bcd71caa0282cbe3c90966f738e2db91e64092a877c3ff7f19a1628fdcb", + "sha256:b50aaac7d05c2c26dfd50c3321199f019ba76bb650e346a6ef3616306eed67b0", + "sha256:b7b6ea9e36d32582cda3465f54c4b454f62f23cb083ebc7a94e2ca6ef011c3a7", + "sha256:bb9333f58fc3a2296fb1d54576138d4cf5d496a2cc118422bd77835e6ae0b9cb", + "sha256:c1c13185b90bbd3f8b5963cd8ce7ad4ff441924c31e23c975cb150e27c2bf67a", + "sha256:c3b8bd3133cd50f6b637bb4322822c94c5ce4bf0d724ed5ae70afce62187c492", + "sha256:c5d97162c196ce54af6700949ddf9409e9833ef1003b4741c2b39ef46f1d9720", + "sha256:c815270206f983309915a6844fe994b2fa47e5d05c4c4cef267c3b30e34dbe42", + "sha256:cab2eba3830bf4f6d91e2d6718e0e1c14a2f5ad1af68a89d24ace0c6b17cced7", + "sha256:d1df34588123fcc88c872f5acb6f74ae59e9d182a2707097f9e28275ec26a12d", + "sha256:d6bdcd415ba87846fd317bee0774e412e8792832e7805938987e4ede1d13046d", + "sha256:db9a30ec064129d605d0f1aedc93e00894b9334ec74ba9c6bdd08147434b33eb", + "sha256:dbc183e7bef690c9abe5ea67b7b60fdbca81aa8da43468287dae7b5c046107d4", + "sha256:dca802c8db0720ce1c49cce1149ff7b06e91ba15fa84b1d59144fef1a1bc7ac2", + "sha256:dec6b307ce928e8e112a6bb9921a1cb00a0e14979bf28b98e084a4b8a742bd9b", + "sha256:df8bb0010fdd0a743b7542589223a2816bdde4d94bb5ad67884348fa2c1c67e8", + "sha256:e4094c7b464cf0a858e75cd14b03509e84789abf7b79f8537e6a72152109c76e", + "sha256:e4760a68cab57bfaa628938e9c2971137e05ce48e762a9cb53b76c9b569f1204", + "sha256:eb09b82377233b902d4c3fbeeb7ad731cdab579c6c6fda1f763cd779139e47c3", + "sha256:eb862356ee9391dc5a0b3cbc00f416b48c1b9a52d252d898e5b7696a5f9fe150", + "sha256:ef9528915df81b8f4c7612b19b8628214c65c9b7f74db2e34a646a0a2a0da2d4", + "sha256:f3157624b7558b914cb039fd1af735e5e8049a87c817cc215109ad1c8779df76", + "sha256:f3e0992f23bbb0be00a921eae5363329253c3b86287db27092461c887b791e5e", + "sha256:f9338cc05451f1942d0d8203ec2c346c830f8e86469903d5126c1f0a13a2bcbb", + "sha256:ffef8fd58a36fb5f1196919638f73dd3ae0db1a878982b27a9a5a176ede4ba91" ], "markers": "platform_python_implementation != 'PyPy'", - "version": "==1.16.0" + "version": "==1.17.0" }, "cryptography": { "hashes": [ - "sha256:02c0eee2d7133bdbbc5e24441258d5d2244beb31da5ed19fbb80315f4bbbff55", - "sha256:0d563795db98b4cd57742a78a288cdbdc9daedac29f2239793071fe114f13785", - "sha256:16268d46086bb8ad5bf0a2b5544d8a9ed87a0e33f5e77dd3c3301e63d941a83b", - "sha256:1a58839984d9cb34c855197043eaae2c187d930ca6d644612843b4fe8513c886", - "sha256:2954fccea107026512b15afb4aa664a5640cd0af630e2ee3962f2602693f0c82", - "sha256:2e47577f9b18723fa294b0ea9a17d5e53a227867a0a4904a1a076d1646d45ca1", - "sha256:31adb7d06fe4383226c3e963471f6837742889b3c4caa55aac20ad951bc8ffda", - "sha256:3577d029bc3f4827dd5bf8bf7710cac13527b470bbf1820a3f394adb38ed7d5f", - "sha256:36017400817987670037fbb0324d71489b6ead6231c9604f8fc1f7d008087c68", - "sha256:362e7197754c231797ec45ee081f3088a27a47c6c01eff2ac83f60f85a50fe60", - "sha256:3de9a45d3b2b7d8088c3fbf1ed4395dfeff79d07842217b38df14ef09ce1d8d7", - "sha256:4f698edacf9c9e0371112792558d2f705b5645076cc0aaae02f816a0171770fd", - "sha256:5482e789294854c28237bba77c4c83be698be740e31a3ae5e879ee5444166582", - "sha256:5e44507bf8d14b36b8389b226665d597bc0f18ea035d75b4e53c7b1ea84583cc", - "sha256:779245e13b9a6638df14641d029add5dc17edbef6ec915688f3acb9e720a5858", - "sha256:789caea816c6704f63f6241a519bfa347f72fbd67ba28d04636b7c6b7da94b0b", - "sha256:7f8b25fa616d8b846aef64b15c606bb0828dbc35faf90566eb139aa9cff67af2", - "sha256:8cb8ce7c3347fcf9446f201dc30e2d5a3c898d009126010cbd1f443f28b52678", - "sha256:93a3209f6bb2b33e725ed08ee0991b92976dfdcf4e8b38646540674fc7508e13", - "sha256:a3a5ac8b56fe37f3125e5b72b61dcde43283e5370827f5233893d461b7360cd4", - "sha256:a47787a5e3649008a1102d3df55424e86606c9bae6fb77ac59afe06d234605f8", - "sha256:a79165431551042cc9d1d90e6145d5d0d3ab0f2d66326c201d9b0e7f5bf43604", - "sha256:a987f840718078212fdf4504d0fd4c6effe34a7e4740378e59d47696e8dfb477", - "sha256:a9bc127cdc4ecf87a5ea22a2556cab6c7eda2923f84e4f3cc588e8470ce4e42e", - "sha256:bd13b5e9b543532453de08bcdc3cc7cebec6f9883e886fd20a92f26940fd3e7a", - "sha256:c65f96dad14f8528a447414125e1fc8feb2ad5a272b8f68477abbcc1ea7d94b9", - "sha256:d8e3098721b84392ee45af2dd554c947c32cc52f862b6a3ae982dbb90f577f14", - "sha256:e6b79d0adb01aae87e8a44c2b64bc3f3fe59515280e00fb6d57a7267a2583cda", - "sha256:e6b8f1881dac458c34778d0a424ae5769de30544fc678eac51c1c8bb2183e9da", - "sha256:e9b2a6309f14c0497f348d08a065d52f3020656f675819fc405fb63bbcd26562", - "sha256:ecbfbc00bf55888edda9868a4cf927205de8499e7fabe6c050322298382953f2", - "sha256:efd0bf5205240182e0f13bcaea41be4fdf5c22c5129fc7ced4a0282ac86998c9" + "sha256:014f58110f53237ace6a408b5beb6c427b64e084eb451ef25a28308270086494", + "sha256:1bbcce1a551e262dfbafb6e6252f1ae36a248e615ca44ba302df077a846a8806", + "sha256:203e92a75716d8cfb491dc47c79e17d0d9207ccffcbcb35f598fbe463ae3444d", + "sha256:27e613d7077ac613e399270253259d9d53872aaf657471473ebfc9a52935c062", + "sha256:2bd51274dcd59f09dd952afb696bf9c61a7a49dfc764c04dd33ef7a6b502a1e2", + "sha256:38926c50cff6f533f8a2dae3d7f19541432610d114a70808f0926d5aaa7121e4", + "sha256:511f4273808ab590912a93ddb4e3914dfd8a388fed883361b02dea3791f292e1", + "sha256:58d4e9129985185a06d849aa6df265bdd5a74ca6e1b736a77959b498e0505b85", + "sha256:5b43d1ea6b378b54a1dc99dd8a2b5be47658fe9a7ce0a58ff0b55f4b43ef2b84", + "sha256:61ec41068b7b74268fa86e3e9e12b9f0c21fcf65434571dbb13d954bceb08042", + "sha256:666ae11966643886c2987b3b721899d250855718d6d9ce41b521252a17985f4d", + "sha256:68aaecc4178e90719e95298515979814bda0cbada1256a4485414860bd7ab962", + "sha256:7c05650fe8023c5ed0d46793d4b7d7e6cd9c04e68eabe5b0aeea836e37bdcec2", + "sha256:80eda8b3e173f0f247f711eef62be51b599b5d425c429b5d4ca6a05e9e856baa", + "sha256:8385d98f6a3bf8bb2d65a73e17ed87a3ba84f6991c155691c51112075f9ffc5d", + "sha256:88cce104c36870d70c49c7c8fd22885875d950d9ee6ab54df2745f83ba0dc365", + "sha256:9d3cdb25fa98afdd3d0892d132b8d7139e2c087da1712041f6b762e4f807cc96", + "sha256:a575913fb06e05e6b4b814d7f7468c2c660e8bb16d8d5a1faf9b33ccc569dd47", + "sha256:ac119bb76b9faa00f48128b7f5679e1d8d437365c5d26f1c2c3f0da4ce1b553d", + "sha256:c1332724be35d23a854994ff0b66530119500b6053d0bd3363265f7e5e77288d", + "sha256:d03a475165f3134f773d1388aeb19c2d25ba88b6a9733c5c590b9ff7bbfa2e0c", + "sha256:d75601ad10b059ec832e78823b348bfa1a59f6b8d545db3a24fd44362a1564cb", + "sha256:de41fd81a41e53267cb020bb3a7212861da53a7d39f863585d13ea11049cf277", + "sha256:e710bf40870f4db63c3d7d929aa9e09e4e7ee219e703f949ec4073b4294f6172", + "sha256:ea25acb556320250756e53f9e20a4177515f012c9eaea17eb7587a8c4d8ae034", + "sha256:f98bf604c82c416bc829e490c700ca1553eafdf2912a91e23a79d97d9801372a", + "sha256:fba1007b3ef89946dbbb515aeeb41e30203b004f0b4b00e5e16078b518563289" ], "index": "pypi", "markers": "python_version >= '3.7'", - "version": "==42.0.7" + "version": "==43.0.1" }, "exceptiongroup": { "hashes": [ @@ -734,11 +752,12 @@ }, "certifi": { "hashes": [ - "sha256:0569859f95fc761b18b45ef421b1290a0f65f147e92a1e5eb3e635f9a5e4e66f", - "sha256:dc383c07b76109f368f6106eee2b593b04a011ea4d55f652c6ca24a754d1cdd1" + "sha256:5a1e7645bc0ec61a09e26c36f6106dd4cf40c6db3a1fb6352b0244e7fb057c7b", + "sha256:c198e21b1289c2ab85ee4e67bb4b4ef3ead0892059901a8d5b622f24a1101e90" ], + "index": "pypi", "markers": "python_version >= '3.6'", - "version": "==2024.2.2" + "version": "==2024.7.4" }, "cffi": { "hashes": [ @@ -1510,11 +1529,12 @@ }, "zipp": { "hashes": [ - "sha256:6278d9ddbcfb1f1089a88fde84481528b07b0e10474e09dcfe53dad4069fa059", - "sha256:dce197b859eb796242b0622af1b8beb0a722d52aa2f57133ead08edd5bf5374e" + "sha256:2828e64edb5386ea6a52e7ba7cdb17bb30a73a858f5eb6eb93d8d36f5ea26091", + "sha256:35427f6d5594f4acf82d25541438348c26736fa9b3afa2754bcd63cdb99d8e8f" ], + "index": "pypi", "markers": "python_version >= '3.8'", - "version": "==3.18.2" + "version": "==3.19.1" } } } diff --git a/database-migration/database.json b/database-migration/database.json index c9ed0d78e3..7a7e104a2c 100644 --- a/database-migration/database.json +++ b/database-migration/database.json @@ -76,6 +76,15 @@ "writeConcern": 1, "numberOfShards": 6 } + }, + { + "type": "documentcollection", + "name": "guidanceTags", + "options": { + "replicationFactor": 3, + "writeConcern": 1, + "numberOfShards": 6 + } }, { "type": "documentcollection", diff --git a/database-migration/index.js b/database-migration/index.js index eeda32087a..cb3bd22864 100644 --- a/database-migration/index.js +++ b/database-migration/index.js @@ -1,5 +1,6 @@ const { config } = require('dotenv-safe') const { ensure } = require('arango-tools') +const { Database } = require('arangojs') config() @@ -8,6 +9,27 @@ const { DB_DESCRIPTION = './database.json', DB_NAME, ROOT_PASS, DB_USER, DB_PASS const schema = require(DB_DESCRIPTION) ;(async () => { + const systemDatabase = new Database({ url: DB_URL, databaseName: '_system' }) + await systemDatabase.login('root', ROOT_PASS) + const databases = await systemDatabase.listDatabases() + if (!databases.includes(DB_NAME)) { + console.log(`Tracker database ${DB_NAME} does not exist. Creating it.`) + try { + await systemDatabase.createDatabase(DB_NAME, { + users: [ + { + username: DB_USER, + passwd: DB_PASS, + active: true, + }, + ], + }) + } catch (e) { + console.error(`Failed to create database ${DB_NAME}: ${e.message}`) + process.exit(1) + } + } + await ensure({ variables: { rootPassword: ROOT_PASS, diff --git a/database-migration/package-lock.json b/database-migration/package-lock.json index 521eca0f3a..674c1df311 100644 --- a/database-migration/package-lock.json +++ b/database-migration/package-lock.json @@ -10,6 +10,7 @@ "license": "MIT", "dependencies": { "arango-tools": "^0.6.0", + "arangojs": "^8.8.1", "dotenv-safe": "^8.2.0", "json-placeholder-replacer": "^1.0.35" }, @@ -115,6 +116,11 @@ "node": ">= 8" } }, + "node_modules/@tokenizer/token": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/@tokenizer/token/-/token-0.3.0.tgz", + "integrity": "sha512-OvjF+z51L3ov0OyAU0duzsYuvO01PH7x4t6DJx+guahgTnBHkhJdG7soQeTSFLWN3efnHyibZ4Z8l2EuWwJN3A==" + }, "node_modules/@types/json5": { "version": "0.0.29", "resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz", @@ -197,7 +203,7 @@ "json-placeholder-replacer": "^1.0.35" } }, - "node_modules/arangojs": { + "node_modules/arango-tools/node_modules/arangojs": { "version": "7.8.0", "resolved": "https://registry.npmjs.org/arangojs/-/arangojs-7.8.0.tgz", "integrity": "sha512-aJFlMKlVr4sIO5GDMuykBVNVxWeZTkWDgYbbl9cIuxVctp8Lhs6dW5fr5MYlwAndnOEyi3bvbrhZIucly2IpWQ==", @@ -212,6 +218,53 @@ "node": ">=10" } }, + "node_modules/arango-tools/node_modules/file-type": { + "version": "12.4.2", + "resolved": "https://registry.npmjs.org/file-type/-/file-type-12.4.2.tgz", + "integrity": "sha512-UssQP5ZgIOKelfsaB5CuGAL+Y+q7EmONuiwF3N5HAH0t27rvrttgi6Ra9k/+DVaY9UF6+ybxu5pOXLUdA8N7Vg==", + "engines": { + "node": ">=8" + } + }, + "node_modules/arango-tools/node_modules/mime-kind": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/mime-kind/-/mime-kind-3.0.0.tgz", + "integrity": "sha512-sx9lClVP7GXY2mO3aVDWTQLhfvAdDvNhGi3o3g7+ae3aKaoybeGbEIlnreoRKjrbDpvlPltlkIryxOtatojeXQ==", + "dependencies": { + "file-type": "^12.1.0", + "mime-types": "^2.1.24" + }, + "engines": { + "node": ">=8.3.0" + } + }, + "node_modules/arango-tools/node_modules/multi-part": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/multi-part/-/multi-part-3.0.0.tgz", + "integrity": "sha512-pDbdYQ6DLDxAsD83w9R7r7rlW56cETL7hIB5bCWX7FJYw0K+kL5JwHr0I8tRk9lGeFcAzf+2OEzXWlG/4wCnFw==", + "dependencies": { + "mime-kind": "^3.0.0", + "multi-part-lite": "^1.0.0" + }, + "engines": { + "node": ">=8.3.0" + } + }, + "node_modules/arangojs": { + "version": "8.8.1", + "resolved": "https://registry.npmjs.org/arangojs/-/arangojs-8.8.1.tgz", + "integrity": "sha512-gVc5BF91nT27lB97mt+XxcGbw7yOhPIkZ0f5Nmq/ZPt1/iP62rDpH961XUyWdzj5m4H8lx2OF/O2AVefZoolXg==", + "dependencies": { + "@types/node": ">=14", + "multi-part": "^4.0.0", + "path-browserify": "^1.0.1", + "x3-linkedlist": "1.2.0", + "xhr": "^2.4.1" + }, + "engines": { + "node": ">=14" + } + }, "node_modules/argparse": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", @@ -1051,11 +1104,19 @@ } }, "node_modules/file-type": { - "version": "12.4.2", - "resolved": "https://registry.npmjs.org/file-type/-/file-type-12.4.2.tgz", - "integrity": "sha512-UssQP5ZgIOKelfsaB5CuGAL+Y+q7EmONuiwF3N5HAH0t27rvrttgi6Ra9k/+DVaY9UF6+ybxu5pOXLUdA8N7Vg==", + "version": "16.5.4", + "resolved": "https://registry.npmjs.org/file-type/-/file-type-16.5.4.tgz", + "integrity": "sha512-/yFHK0aGjFEgDJjEKP0pWCplsPFPhwyfwevf/pVxiN0tmE4L9LmwWxWukdJSHdoCli4VgQLehjJtwQBnqmsKcw==", + "dependencies": { + "readable-web-to-node-stream": "^3.0.0", + "strtok3": "^6.2.4", + "token-types": "^4.1.1" + }, "engines": { - "node": ">=8" + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sindresorhus/file-type?sponsor=1" } }, "node_modules/find-up": { @@ -1305,6 +1366,25 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, "node_modules/ignore": { "version": "5.2.4", "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.2.4.tgz", @@ -1352,8 +1432,7 @@ "node_modules/inherits": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "dev": true + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" }, "node_modules/internal-slot": { "version": "1.0.4", @@ -1685,15 +1764,15 @@ } }, "node_modules/mime-kind": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/mime-kind/-/mime-kind-3.0.0.tgz", - "integrity": "sha512-sx9lClVP7GXY2mO3aVDWTQLhfvAdDvNhGi3o3g7+ae3aKaoybeGbEIlnreoRKjrbDpvlPltlkIryxOtatojeXQ==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/mime-kind/-/mime-kind-4.0.0.tgz", + "integrity": "sha512-qQvglvSpS5mABi30beNFd+uHKtKkxD3dxAmhi2e589XKx+WfVqhg5i5P5LBcVgwwv3BiDpNMBWrHqU+JexW4aA==", "dependencies": { - "file-type": "^12.1.0", + "file-type": "^16.5.4", "mime-types": "^2.1.24" }, "engines": { - "node": ">=8.3.0" + "node": ">=10" } }, "node_modules/mime-types": { @@ -1743,15 +1822,15 @@ "dev": true }, "node_modules/multi-part": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/multi-part/-/multi-part-3.0.0.tgz", - "integrity": "sha512-pDbdYQ6DLDxAsD83w9R7r7rlW56cETL7hIB5bCWX7FJYw0K+kL5JwHr0I8tRk9lGeFcAzf+2OEzXWlG/4wCnFw==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/multi-part/-/multi-part-4.0.0.tgz", + "integrity": "sha512-YT/CS0PAe62kT8EoQXcQj8yIcSu18HhYv0s6ShdAFsoFly3oV5QaxODnkj0u7zH0/RFyH47cdcMVpcGXliEFVA==", "dependencies": { - "mime-kind": "^3.0.0", + "mime-kind": "^4.0.0", "multi-part-lite": "^1.0.0" }, "engines": { - "node": ">=8.3.0" + "node": ">=10" } }, "node_modules/multi-part-lite": { @@ -1894,6 +1973,11 @@ "resolved": "https://registry.npmjs.org/parse-headers/-/parse-headers-2.0.5.tgz", "integrity": "sha512-ft3iAoLOB/MlwbNXgzy43SWGP6sQki2jQvAyBg/zDFAgr9bfNWZIUj42Kw2eJIl8kEi4PbgE6U1Zau/HwI75HA==" }, + "node_modules/path-browserify": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-browserify/-/path-browserify-1.0.1.tgz", + "integrity": "sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g==" + }, "node_modules/path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -1927,6 +2011,18 @@ "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", "dev": true }, + "node_modules/peek-readable": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/peek-readable/-/peek-readable-4.1.0.tgz", + "integrity": "sha512-ZI3LnwUv5nOGbQzD9c2iDG6toheuXSZP5esSHBjopsXH4dg19soufvpUGA3uohi5anFtGb2lhAVdHzH6R/Evvg==", + "engines": { + "node": ">=8" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/Borewit" + } + }, "node_modules/prelude-ls": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", @@ -1988,6 +2084,34 @@ } ] }, + "node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/readable-web-to-node-stream": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/readable-web-to-node-stream/-/readable-web-to-node-stream-3.0.2.tgz", + "integrity": "sha512-ePeK6cc1EcKLEhJFt/AebMCLL+GgSKhuygrZ/GLaKZYEecIgIECf4UaUuaByiGtzckwR4ain9VzUh95T1exYGw==", + "dependencies": { + "readable-stream": "^3.6.0" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/Borewit" + } + }, "node_modules/regexp.prototype.flags": { "version": "1.4.3", "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.4.3.tgz", @@ -2091,6 +2215,25 @@ "queue-microtask": "^1.2.2" } }, + "node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, "node_modules/safe-regex-test": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz", @@ -2156,6 +2299,14 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "dependencies": { + "safe-buffer": "~5.2.0" + } + }, "node_modules/string.prototype.trimend": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.6.tgz", @@ -2217,6 +2368,22 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/strtok3": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/strtok3/-/strtok3-6.3.0.tgz", + "integrity": "sha512-fZtbhtvI9I48xDSywd/somNqgUHl2L2cstmXCCif0itOf96jeW18MBSyrLuNicYQVkvpOxkZtkzujiTJ9LW5Jw==", + "dependencies": { + "@tokenizer/token": "^0.3.0", + "peek-readable": "^4.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/Borewit" + } + }, "node_modules/supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", @@ -2247,6 +2414,22 @@ "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==", "dev": true }, + "node_modules/token-types": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/token-types/-/token-types-4.2.1.tgz", + "integrity": "sha512-6udB24Q737UD/SDsKAHI9FCRP7Bqc9D/MQUV02ORQg5iskjtLJlZJNdN4kKtcdtwCeWIwIHDGaUsTsCCAa8sFQ==", + "dependencies": { + "@tokenizer/token": "^0.3.0", + "ieee754": "^1.2.1" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/Borewit" + } + }, "node_modules/tsconfig-paths": { "version": "3.14.1", "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.14.1.tgz", @@ -2307,6 +2490,11 @@ "punycode": "^2.1.0" } }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" + }, "node_modules/which": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", @@ -2467,6 +2655,11 @@ "fastq": "^1.6.0" } }, + "@tokenizer/token": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/@tokenizer/token/-/token-0.3.0.tgz", + "integrity": "sha512-OvjF+z51L3ov0OyAU0duzsYuvO01PH7x4t6DJx+guahgTnBHkhJdG7soQeTSFLWN3efnHyibZ4Z8l2EuWwJN3A==" + }, "@types/json5": { "version": "0.0.29", "resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz", @@ -2526,16 +2719,53 @@ "arangojs": "^7.2.0", "assign-deep": "^1.0.1", "json-placeholder-replacer": "^1.0.35" + }, + "dependencies": { + "arangojs": { + "version": "7.8.0", + "resolved": "https://registry.npmjs.org/arangojs/-/arangojs-7.8.0.tgz", + "integrity": "sha512-aJFlMKlVr4sIO5GDMuykBVNVxWeZTkWDgYbbl9cIuxVctp8Lhs6dW5fr5MYlwAndnOEyi3bvbrhZIucly2IpWQ==", + "requires": { + "@types/node": ">=13.13.4", + "es6-error": "^4.0.1", + "multi-part": "^3.0.0", + "x3-linkedlist": "1.2.0", + "xhr": "^2.4.1" + } + }, + "file-type": { + "version": "12.4.2", + "resolved": "https://registry.npmjs.org/file-type/-/file-type-12.4.2.tgz", + "integrity": "sha512-UssQP5ZgIOKelfsaB5CuGAL+Y+q7EmONuiwF3N5HAH0t27rvrttgi6Ra9k/+DVaY9UF6+ybxu5pOXLUdA8N7Vg==" + }, + "mime-kind": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/mime-kind/-/mime-kind-3.0.0.tgz", + "integrity": "sha512-sx9lClVP7GXY2mO3aVDWTQLhfvAdDvNhGi3o3g7+ae3aKaoybeGbEIlnreoRKjrbDpvlPltlkIryxOtatojeXQ==", + "requires": { + "file-type": "^12.1.0", + "mime-types": "^2.1.24" + } + }, + "multi-part": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/multi-part/-/multi-part-3.0.0.tgz", + "integrity": "sha512-pDbdYQ6DLDxAsD83w9R7r7rlW56cETL7hIB5bCWX7FJYw0K+kL5JwHr0I8tRk9lGeFcAzf+2OEzXWlG/4wCnFw==", + "requires": { + "mime-kind": "^3.0.0", + "multi-part-lite": "^1.0.0" + } + } } }, "arangojs": { - "version": "7.8.0", - "resolved": "https://registry.npmjs.org/arangojs/-/arangojs-7.8.0.tgz", - "integrity": "sha512-aJFlMKlVr4sIO5GDMuykBVNVxWeZTkWDgYbbl9cIuxVctp8Lhs6dW5fr5MYlwAndnOEyi3bvbrhZIucly2IpWQ==", + "version": "8.8.1", + "resolved": "https://registry.npmjs.org/arangojs/-/arangojs-8.8.1.tgz", + "integrity": "sha512-gVc5BF91nT27lB97mt+XxcGbw7yOhPIkZ0f5Nmq/ZPt1/iP62rDpH961XUyWdzj5m4H8lx2OF/O2AVefZoolXg==", "requires": { - "@types/node": ">=13.13.4", - "es6-error": "^4.0.1", - "multi-part": "^3.0.0", + "@types/node": ">=14", + "multi-part": "^4.0.0", + "path-browserify": "^1.0.1", "x3-linkedlist": "1.2.0", "xhr": "^2.4.1" } @@ -3152,9 +3382,14 @@ } }, "file-type": { - "version": "12.4.2", - "resolved": "https://registry.npmjs.org/file-type/-/file-type-12.4.2.tgz", - "integrity": "sha512-UssQP5ZgIOKelfsaB5CuGAL+Y+q7EmONuiwF3N5HAH0t27rvrttgi6Ra9k/+DVaY9UF6+ybxu5pOXLUdA8N7Vg==" + "version": "16.5.4", + "resolved": "https://registry.npmjs.org/file-type/-/file-type-16.5.4.tgz", + "integrity": "sha512-/yFHK0aGjFEgDJjEKP0pWCplsPFPhwyfwevf/pVxiN0tmE4L9LmwWxWukdJSHdoCli4VgQLehjJtwQBnqmsKcw==", + "requires": { + "readable-web-to-node-stream": "^3.0.0", + "strtok3": "^6.2.4", + "token-types": "^4.1.1" + } }, "find-up": { "version": "5.0.0", @@ -3334,6 +3569,11 @@ "has-symbols": "^1.0.2" } }, + "ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==" + }, "ignore": { "version": "5.2.4", "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.2.4.tgz", @@ -3369,8 +3609,7 @@ "inherits": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "dev": true + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" }, "internal-slot": { "version": "1.0.4", @@ -3601,11 +3840,11 @@ "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==" }, "mime-kind": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/mime-kind/-/mime-kind-3.0.0.tgz", - "integrity": "sha512-sx9lClVP7GXY2mO3aVDWTQLhfvAdDvNhGi3o3g7+ae3aKaoybeGbEIlnreoRKjrbDpvlPltlkIryxOtatojeXQ==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/mime-kind/-/mime-kind-4.0.0.tgz", + "integrity": "sha512-qQvglvSpS5mABi30beNFd+uHKtKkxD3dxAmhi2e589XKx+WfVqhg5i5P5LBcVgwwv3BiDpNMBWrHqU+JexW4aA==", "requires": { - "file-type": "^12.1.0", + "file-type": "^16.5.4", "mime-types": "^2.1.24" } }, @@ -3647,11 +3886,11 @@ "dev": true }, "multi-part": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/multi-part/-/multi-part-3.0.0.tgz", - "integrity": "sha512-pDbdYQ6DLDxAsD83w9R7r7rlW56cETL7hIB5bCWX7FJYw0K+kL5JwHr0I8tRk9lGeFcAzf+2OEzXWlG/4wCnFw==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/multi-part/-/multi-part-4.0.0.tgz", + "integrity": "sha512-YT/CS0PAe62kT8EoQXcQj8yIcSu18HhYv0s6ShdAFsoFly3oV5QaxODnkj0u7zH0/RFyH47cdcMVpcGXliEFVA==", "requires": { - "mime-kind": "^3.0.0", + "mime-kind": "^4.0.0", "multi-part-lite": "^1.0.0" } }, @@ -3756,6 +3995,11 @@ "resolved": "https://registry.npmjs.org/parse-headers/-/parse-headers-2.0.5.tgz", "integrity": "sha512-ft3iAoLOB/MlwbNXgzy43SWGP6sQki2jQvAyBg/zDFAgr9bfNWZIUj42Kw2eJIl8kEi4PbgE6U1Zau/HwI75HA==" }, + "path-browserify": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-browserify/-/path-browserify-1.0.1.tgz", + "integrity": "sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g==" + }, "path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -3780,6 +4024,11 @@ "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", "dev": true }, + "peek-readable": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/peek-readable/-/peek-readable-4.1.0.tgz", + "integrity": "sha512-ZI3LnwUv5nOGbQzD9c2iDG6toheuXSZP5esSHBjopsXH4dg19soufvpUGA3uohi5anFtGb2lhAVdHzH6R/Evvg==" + }, "prelude-ls": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", @@ -3809,6 +4058,24 @@ "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", "dev": true }, + "readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "requires": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + } + }, + "readable-web-to-node-stream": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/readable-web-to-node-stream/-/readable-web-to-node-stream-3.0.2.tgz", + "integrity": "sha512-ePeK6cc1EcKLEhJFt/AebMCLL+GgSKhuygrZ/GLaKZYEecIgIECf4UaUuaByiGtzckwR4ain9VzUh95T1exYGw==", + "requires": { + "readable-stream": "^3.6.0" + } + }, "regexp.prototype.flags": { "version": "1.4.3", "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.4.3.tgz", @@ -3867,6 +4134,11 @@ "queue-microtask": "^1.2.2" } }, + "safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" + }, "safe-regex-test": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz", @@ -3914,6 +4186,14 @@ "object-inspect": "^1.9.0" } }, + "string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "requires": { + "safe-buffer": "~5.2.0" + } + }, "string.prototype.trimend": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.6.tgz", @@ -3957,6 +4237,15 @@ "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", "dev": true }, + "strtok3": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/strtok3/-/strtok3-6.3.0.tgz", + "integrity": "sha512-fZtbhtvI9I48xDSywd/somNqgUHl2L2cstmXCCif0itOf96jeW18MBSyrLuNicYQVkvpOxkZtkzujiTJ9LW5Jw==", + "requires": { + "@tokenizer/token": "^0.3.0", + "peek-readable": "^4.1.0" + } + }, "supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", @@ -3978,6 +4267,15 @@ "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==", "dev": true }, + "token-types": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/token-types/-/token-types-4.2.1.tgz", + "integrity": "sha512-6udB24Q737UD/SDsKAHI9FCRP7Bqc9D/MQUV02ORQg5iskjtLJlZJNdN4kKtcdtwCeWIwIHDGaUsTsCCAa8sFQ==", + "requires": { + "@tokenizer/token": "^0.3.0", + "ieee754": "^1.2.1" + } + }, "tsconfig-paths": { "version": "3.14.1", "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.14.1.tgz", @@ -4026,6 +4324,11 @@ "punycode": "^2.1.0" } }, + "util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" + }, "which": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", diff --git a/database-migration/package.json b/database-migration/package.json index 6ecf18bbae..c2659b04ea 100644 --- a/database-migration/package.json +++ b/database-migration/package.json @@ -12,6 +12,7 @@ "license": "MIT", "dependencies": { "arango-tools": "^0.6.0", + "arangojs": "^8.8.1", "dotenv-safe": "^8.2.0", "json-placeholder-replacer": "^1.0.35" }, diff --git a/frontend/Dockerfile b/frontend/Dockerfile index 7aad2a6e93..03d83f92a6 100644 --- a/frontend/Dockerfile +++ b/frontend/Dockerfile @@ -1,4 +1,4 @@ -FROM node:17-alpine as build-env +FROM node:20.16-alpine3.19 as build-env WORKDIR /app @@ -7,9 +7,7 @@ COPY . . RUN npm ci && npm run build && npm prune --production -# https://github.com/astefanutti/scratch-node -FROM astefanutti/scratch-node:17 -LABEL maintainer="mike.williamson@tbs-sct.gc.ca" +FROM gcr.io/distroless/nodejs20-debian12 ENV HOST 0.0.0.0 ENV PORT 3000 @@ -22,8 +20,7 @@ ENV NODE_ENV production # https://github.com/webpack/webpack/issues/14532#issuecomment-947012063 ENV NODE_OPTIONS=--openssl-legacy-provider -USER node +USER nonroot EXPOSE 3000 -ENTRYPOINT ["/bin/node"] CMD ["index.js"] diff --git a/frontend/package-lock.json b/frontend/package-lock.json index 70bd23b520..4d7af54bc5 100644 --- a/frontend/package-lock.json +++ b/frontend/package-lock.json @@ -16,7 +16,7 @@ "@chakra-ui/system": "^2.6.2", "@emotion/react": "^11.9.3", "@emotion/styled": "^11.9.3", - "@lingui/react": "^3.14.0", + "@lingui/react": "^4.11.3", "@visx/axis": "^2.17.0", "@visx/curve": "^3.3.0", "@visx/event": "^2.17.0", @@ -31,11 +31,11 @@ "@visx/shape": "^3.5.0", "@visx/tooltip": "^2.17.0", "@visx/vendor": "^3.5.0", - "body-parser": "^1.19.1", + "body-parser": "^1.20.3", "compression": "^1.7.4", "d3": "^7.8.0", "dotenv": "^16.0.1", - "express": "^4.19.2", + "express": "^4.20.0", "formik": "^2.2.9", "framer-motion": "^4.1.17", "isomorphic-unfetch": "^3.1.0", @@ -60,9 +60,10 @@ "@babel/preset-react": "^7.18.6", "@graphql-tools/mock": "^8.7.0", "@graphql-tools/schema": "^10.0.0", - "@lingui/cli": "^3.14.0", - "@lingui/loader": "^3.14.0", - "@lingui/macro": "^3.14.0", + "@lingui/cli": "^4.11.3", + "@lingui/core": "^4.11.3", + "@lingui/loader": "^4.11.3", + "@lingui/macro": "^4.11.3", "@testing-library/jest-dom": "^5.16.4", "@testing-library/react": "^13.4.0", "@testing-library/react-hooks": "^7.0.2", @@ -93,7 +94,7 @@ "react-test-renderer": "^18.2.0", "source-map-loader": "^4.0.0", "supertest": "^6.2.3", - "webpack": "^5.76.2", + "webpack": "^5.94.0", "webpack-cli": "^4.10.0", "webpack-config-utils": "^2.3.1", "webpack-dev-server": "^4.9.2" @@ -392,47 +393,47 @@ } }, "node_modules/@babel/code-frame": { - "version": "7.22.13", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.22.13.tgz", - "integrity": "sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w==", + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.24.7.tgz", + "integrity": "sha512-BcYH1CVJBO9tvyIZ2jVeXgSIMvGZ2FDRvDdOIVQyuklNKSsx+eppDEBq/g47Ayw+RqNFE+URvOShmf+f/qwAlA==", "dependencies": { - "@babel/highlight": "^7.22.13", - "chalk": "^2.4.2" + "@babel/highlight": "^7.24.7", + "picocolors": "^1.0.0" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/compat-data": { - "version": "7.18.8", - "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.18.8.tgz", - "integrity": "sha512-HSmX4WZPPK3FUxYp7g2T6EyO8j96HlZJlxmKPSh6KAcqwyDrfx7hKjXpAW/0FhFfTJsR0Yt4lAjLI2coMptIHQ==", + "version": "7.25.4", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.25.4.tgz", + "integrity": "sha512-+LGRog6RAsCJrrrg/IO6LGmpphNe5DiK30dGjCoxxeGv49B10/3XYGxPsAwrDlMFcFEvdAUavDT8r9k/hSyQqQ==", "devOptional": true, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/core": { - "version": "7.18.10", - "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.18.10.tgz", - "integrity": "sha512-JQM6k6ENcBFKVtWvLavlvi/mPcpYZ3+R+2EySDEMSMbp7Mn4FexlbbJVrx2R7Ijhr01T8gyqrOaABWIOgxeUyw==", + "version": "7.25.2", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.25.2.tgz", + "integrity": "sha512-BBt3opiCOxUr9euZ5/ro/Xv8/V7yJ5bjYMqG/C1YAo8MIKAnumZalCN+msbci3Pigy4lIQfPUpfMM27HMGaYEA==", "devOptional": true, "dependencies": { - "@ampproject/remapping": "^2.1.0", - "@babel/code-frame": "^7.18.6", - "@babel/generator": "^7.18.10", - "@babel/helper-compilation-targets": "^7.18.9", - "@babel/helper-module-transforms": "^7.18.9", - "@babel/helpers": "^7.18.9", - "@babel/parser": "^7.18.10", - "@babel/template": "^7.18.10", - "@babel/traverse": "^7.18.10", - "@babel/types": "^7.18.10", - "convert-source-map": "^1.7.0", + "@ampproject/remapping": "^2.2.0", + "@babel/code-frame": "^7.24.7", + "@babel/generator": "^7.25.0", + "@babel/helper-compilation-targets": "^7.25.2", + "@babel/helper-module-transforms": "^7.25.2", + "@babel/helpers": "^7.25.0", + "@babel/parser": "^7.25.0", + "@babel/template": "^7.25.0", + "@babel/traverse": "^7.25.2", + "@babel/types": "^7.25.2", + "convert-source-map": "^2.0.0", "debug": "^4.1.0", "gensync": "^1.0.0-beta.2", - "json5": "^2.2.1", - "semver": "^6.3.0" + "json5": "^2.2.3", + "semver": "^6.3.1" }, "engines": { "node": ">=6.9.0" @@ -442,6 +443,12 @@ "url": "https://opencollective.com/babel" } }, + "node_modules/@babel/core/node_modules/convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", + "devOptional": true + }, "node_modules/@babel/core/node_modules/debug": { "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", @@ -475,14 +482,13 @@ } }, "node_modules/@babel/generator": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.23.0.tgz", - "integrity": "sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g==", - "devOptional": true, + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.25.6.tgz", + "integrity": "sha512-VPC82gr1seXOpkjAAKoLhP50vx4vGNlF4msF64dSFq1P8RfB+QAuJWGHPXXPc8QyfVWwwB/TNNU4+ayZmHNbZw==", "dependencies": { - "@babel/types": "^7.23.0", - "@jridgewell/gen-mapping": "^0.3.2", - "@jridgewell/trace-mapping": "^0.3.17", + "@babel/types": "^7.25.6", + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.25", "jsesc": "^2.5.1" }, "engines": { @@ -490,14 +496,13 @@ } }, "node_modules/@babel/generator/node_modules/@jridgewell/gen-mapping": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.2.tgz", - "integrity": "sha512-mh65xKQAzI6iBcFzwv28KVWSmCkdRBWoOh+bYQGW3+6OZvbbN3TqMGo5hqYxQniRcH9F2VZIoJCm4pa3BPDK/A==", - "devOptional": true, + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", + "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==", "dependencies": { - "@jridgewell/set-array": "^1.0.1", + "@jridgewell/set-array": "^1.2.1", "@jridgewell/sourcemap-codec": "^1.4.10", - "@jridgewell/trace-mapping": "^0.3.9" + "@jridgewell/trace-mapping": "^0.3.24" }, "engines": { "node": ">=6.0.0" @@ -529,21 +534,28 @@ } }, "node_modules/@babel/helper-compilation-targets": { - "version": "7.18.9", - "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.18.9.tgz", - "integrity": "sha512-tzLCyVmqUiFlcFoAPLA/gL9TeYrF61VLNtb+hvkuVaB5SUjW7jcfrglBIX1vUIoT7CLP3bBlIMeyEsIl2eFQNg==", + "version": "7.25.2", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.25.2.tgz", + "integrity": "sha512-U2U5LsSaZ7TAt3cfaymQ8WHh0pxvdHoEk6HVpaexxixjyEquMh0L0YNJNM6CTGKMXV1iksi0iZkGw4AcFkPaaw==", "devOptional": true, "dependencies": { - "@babel/compat-data": "^7.18.8", - "@babel/helper-validator-option": "^7.18.6", - "browserslist": "^4.20.2", - "semver": "^6.3.0" + "@babel/compat-data": "^7.25.2", + "@babel/helper-validator-option": "^7.24.8", + "browserslist": "^4.23.1", + "lru-cache": "^5.1.1", + "semver": "^6.3.1" }, "engines": { "node": ">=6.9.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-compilation-targets/node_modules/lru-cache": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", + "integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==", + "devOptional": true, + "dependencies": { + "yallist": "^3.0.2" } }, "node_modules/@babel/helper-compilation-targets/node_modules/semver": { @@ -555,6 +567,12 @@ "semver": "bin/semver.js" } }, + "node_modules/@babel/helper-compilation-targets/node_modules/yallist": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", + "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==", + "devOptional": true + }, "node_modules/@babel/helper-create-class-features-plugin": { "version": "7.18.9", "resolved": "https://registry.npmjs.org/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.18.9.tgz", @@ -645,7 +663,7 @@ "version": "7.22.20", "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.22.20.tgz", "integrity": "sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA==", - "devOptional": true, + "dev": true, "engines": { "node": ">=6.9.0" } @@ -666,7 +684,7 @@ "version": "7.23.0", "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.23.0.tgz", "integrity": "sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==", - "devOptional": true, + "dev": true, "dependencies": { "@babel/template": "^7.22.15", "@babel/types": "^7.23.0" @@ -679,7 +697,7 @@ "version": "7.22.5", "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.22.5.tgz", "integrity": "sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==", - "devOptional": true, + "dev": true, "dependencies": { "@babel/types": "^7.22.5" }, @@ -700,33 +718,33 @@ } }, "node_modules/@babel/helper-module-imports": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.18.6.tgz", - "integrity": "sha512-0NFvs3VkuSYbFi1x2Vd6tKrywq+z/cLeYC/RJNFrIX/30Bf5aiGYbtvGXolEktzJH8o5E5KJ3tT+nkxuuZFVlA==", + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.24.7.tgz", + "integrity": "sha512-8AyH3C+74cgCVVXow/myrynrAGv+nTVg5vKu2nZph9x7RcRwzmh0VFallJuFTZ9mx6u4eSdXZfcOzSqTUm0HCA==", "dependencies": { - "@babel/types": "^7.18.6" + "@babel/traverse": "^7.24.7", + "@babel/types": "^7.24.7" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helper-module-transforms": { - "version": "7.18.9", - "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.18.9.tgz", - "integrity": "sha512-KYNqY0ICwfv19b31XzvmI/mfcylOzbLtowkw+mfvGPAQ3kfCnMLYbED3YecL5tPd8nAYFQFAd6JHp2LxZk/J1g==", + "version": "7.25.2", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.25.2.tgz", + "integrity": "sha512-BjyRAbix6j/wv83ftcVJmBt72QtHI56C7JXZoG2xATiLpmoC7dpd8WnkikExHDVPpi/3qCmO6WY1EaXOluiecQ==", "devOptional": true, "dependencies": { - "@babel/helper-environment-visitor": "^7.18.9", - "@babel/helper-module-imports": "^7.18.6", - "@babel/helper-simple-access": "^7.18.6", - "@babel/helper-split-export-declaration": "^7.18.6", - "@babel/helper-validator-identifier": "^7.18.6", - "@babel/template": "^7.18.6", - "@babel/traverse": "^7.18.9", - "@babel/types": "^7.18.9" + "@babel/helper-module-imports": "^7.24.7", + "@babel/helper-simple-access": "^7.24.7", + "@babel/helper-validator-identifier": "^7.24.7", + "@babel/traverse": "^7.25.2" }, "engines": { "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" } }, "node_modules/@babel/helper-optimise-call-expression": { @@ -785,12 +803,13 @@ } }, "node_modules/@babel/helper-simple-access": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.18.6.tgz", - "integrity": "sha512-iNpIgTgyAvDQpDj76POqg+YEt8fPxx3yaNBg3S30dxNKm2SWfYhD0TGrK/Eu9wHpUW63VQU894TsTg+GLbUa1g==", + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.24.7.tgz", + "integrity": "sha512-zBAIvbCMh5Ts+b86r/CjU+4XGYIs+R1j951gxI3KmmxBMhCg4oQMsv6ZXQ64XOm/cvzfU1FmoCyt6+owc5QMYg==", "devOptional": true, "dependencies": { - "@babel/types": "^7.18.6" + "@babel/traverse": "^7.24.7", + "@babel/types": "^7.24.7" }, "engines": { "node": ">=6.9.0" @@ -812,7 +831,7 @@ "version": "7.22.6", "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.22.6.tgz", "integrity": "sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==", - "devOptional": true, + "dev": true, "dependencies": { "@babel/types": "^7.22.5" }, @@ -821,25 +840,25 @@ } }, "node_modules/@babel/helper-string-parser": { - "version": "7.22.5", - "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.22.5.tgz", - "integrity": "sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw==", + "version": "7.24.8", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.24.8.tgz", + "integrity": "sha512-pO9KhhRcuUyGnJWwyEgnRJTSIZHiT+vMD0kPeD+so0l7mxkMT19g3pjY9GTnHySck/hDzq+dtW/4VgnMkippsQ==", "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helper-validator-identifier": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.20.tgz", - "integrity": "sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==", + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.24.7.tgz", + "integrity": "sha512-rR+PBcQ1SMQDDyF6X0wxtG8QyLCgUB0eRAGguqRLfkCA87l7yAP7ehq8SNj96OOGTO8OBV70KhuFYcIkHXOg0w==", "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/helper-validator-option": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.18.6.tgz", - "integrity": "sha512-XO7gESt5ouv/LRJdrVjkShckw6STTaB7l9BrpBaAHDeF5YZT+01PCwmR0SJHnkW6i8OwW/EVWRShfi4j2x+KQw==", + "version": "7.24.8", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.24.8.tgz", + "integrity": "sha512-xb8t9tD1MHLungh/AIoWYN+gVHaB9kwlu8gffXGSt3FFEIT7RjS+xWbc2vUD1UTZdIpKj/ab3rdqJ7ufngyi2Q==", "devOptional": true, "engines": { "node": ">=6.9.0" @@ -861,37 +880,39 @@ } }, "node_modules/@babel/helpers": { - "version": "7.18.9", - "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.18.9.tgz", - "integrity": "sha512-Jf5a+rbrLoR4eNdUmnFu8cN5eNJT6qdTdOg5IHIzq87WwyRw9PwguLFOWYgktN/60IP4fgDUawJvs7PjQIzELQ==", + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.25.6.tgz", + "integrity": "sha512-Xg0tn4HcfTijTwfDwYlvVCl43V6h4KyVVX2aEm4qdO/PC6L2YvzLHFdmxhoeSA3eslcE6+ZVXHgWwopXYLNq4Q==", "devOptional": true, "dependencies": { - "@babel/template": "^7.18.6", - "@babel/traverse": "^7.18.9", - "@babel/types": "^7.18.9" + "@babel/template": "^7.25.0", + "@babel/types": "^7.25.6" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/highlight": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.22.20.tgz", - "integrity": "sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg==", + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.24.7.tgz", + "integrity": "sha512-EStJpq4OuY8xYfhGVXngigBJRWxftKX9ksiGDnmlY3o7B/V7KIAc9X4oiK87uPJSc/vs5L869bem5fhZa8caZw==", "dependencies": { - "@babel/helper-validator-identifier": "^7.22.20", + "@babel/helper-validator-identifier": "^7.24.7", "chalk": "^2.4.2", - "js-tokens": "^4.0.0" + "js-tokens": "^4.0.0", + "picocolors": "^1.0.0" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/parser": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.23.0.tgz", - "integrity": "sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw==", - "devOptional": true, + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.25.6.tgz", + "integrity": "sha512-trGdfBdbD0l1ZPmcJ83eNxB9rbEax4ALFTF7fN386TMYbeCQbyme5cOEXQhbGXKebwGaB/J52w1mrklMcbgy6Q==", + "dependencies": { + "@babel/types": "^7.25.6" + }, "bin": { "parser": "bin/babel-parser.js" }, @@ -2118,45 +2139,40 @@ } }, "node_modules/@babel/runtime": { - "version": "7.18.9", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.18.9.tgz", - "integrity": "sha512-lkqXDcvlFT5rvEjiu6+QYO+1GXrEHRo2LOtS7E4GtX5ESIZOgepqsZBVIj6Pv+a6zqsya9VCgiK1KAK4BvJDAw==", + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "dependencies": { - "regenerator-runtime": "^0.13.4" + "regenerator-runtime": "^0.14.0" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/template": { - "version": "7.22.15", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.22.15.tgz", - "integrity": "sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w==", - "devOptional": true, + "version": "7.25.0", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.25.0.tgz", + "integrity": "sha512-aOOgh1/5XzKvg1jvVz7AVrx2piJ2XBi227DHmbY6y+bM9H2FlN+IfecYu4Xl0cNiiVejlsCri89LUsbj8vJD9Q==", "dependencies": { - "@babel/code-frame": "^7.22.13", - "@babel/parser": "^7.22.15", - "@babel/types": "^7.22.15" + "@babel/code-frame": "^7.24.7", + "@babel/parser": "^7.25.0", + "@babel/types": "^7.25.0" }, "engines": { "node": ">=6.9.0" } }, "node_modules/@babel/traverse": { - "version": "7.23.2", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.23.2.tgz", - "integrity": "sha512-azpe59SQ48qG6nu2CzcMLbxUudtN+dOM9kDbUqGq3HXUJRlo7i8fvPoxQUzYgLZ4cMVmuZgm8vvBpNeRhd6XSw==", - "devOptional": true, - "dependencies": { - "@babel/code-frame": "^7.22.13", - "@babel/generator": "^7.23.0", - "@babel/helper-environment-visitor": "^7.22.20", - "@babel/helper-function-name": "^7.23.0", - "@babel/helper-hoist-variables": "^7.22.5", - "@babel/helper-split-export-declaration": "^7.22.6", - "@babel/parser": "^7.23.0", - "@babel/types": "^7.23.0", - "debug": "^4.1.0", + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.25.6.tgz", + "integrity": "sha512-9Vrcx5ZW6UwK5tvqsj0nGpp/XzqthkT0dqIc9g1AdtygFToNtTF67XzYS//dm+SAK9cp3B9R4ZO/46p63SCjlQ==", + "dependencies": { + "@babel/code-frame": "^7.24.7", + "@babel/generator": "^7.25.6", + "@babel/parser": "^7.25.6", + "@babel/template": "^7.25.0", + "@babel/types": "^7.25.6", + "debug": "^4.3.1", "globals": "^11.1.0" }, "engines": { @@ -2167,7 +2183,6 @@ "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", - "devOptional": true, "dependencies": { "ms": "2.1.2" }, @@ -2183,16 +2198,15 @@ "node_modules/@babel/traverse/node_modules/ms": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "devOptional": true + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" }, "node_modules/@babel/types": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.23.0.tgz", - "integrity": "sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg==", + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.25.6.tgz", + "integrity": "sha512-/l42B1qxpG6RdfYf343Uw1vmDjeNhneUXtzhojE7pDgfpEypmRhI6j1kr17XCVv4Cgl9HdAiQY2x0GwKm7rWCw==", "dependencies": { - "@babel/helper-string-parser": "^7.22.5", - "@babel/helper-validator-identifier": "^7.22.20", + "@babel/helper-string-parser": "^7.24.8", + "@babel/helper-validator-identifier": "^7.24.7", "to-fast-properties": "^2.0.0" }, "engines": { @@ -3753,29 +3767,357 @@ "resolved": "https://registry.npmjs.org/@emotion/weak-memoize/-/weak-memoize-0.3.1.tgz", "integrity": "sha512-EsBwpc7hBUJWAsNPBmJy4hxWx12v6bshQsldrVmjxJoc3isbxhOrF2IcCpaXxfvq03NwkI7sbsOLXbYuqF/8Ww==" }, - "node_modules/@endemolshinegroup/cosmiconfig-typescript-loader": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/@endemolshinegroup/cosmiconfig-typescript-loader/-/cosmiconfig-typescript-loader-3.0.2.tgz", - "integrity": "sha512-QRVtqJuS1mcT56oHpVegkKBlgtWjXw/gHNWO3eL9oyB5Sc7HBoc2OLG/nYpVfT/Jejvo3NUrD0Udk7XgoyDKkA==", + "node_modules/@esbuild/android-arm": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.17.19.tgz", + "integrity": "sha512-rIKddzqhmav7MSmoFCmDIb6e2W57geRsM94gV2l38fzhXMwq7hZoClug9USI2pFRGL06f4IOPHHpFNOkWieR8A==", + "cpu": [ + "arm" + ], "dev": true, - "dependencies": { - "lodash.get": "^4", - "make-error": "^1", - "ts-node": "^9", - "tslib": "^2" - }, + "optional": true, + "os": [ + "android" + ], "engines": { - "node": ">=10.0.0" - }, - "peerDependencies": { - "cosmiconfig": ">=6" + "node": ">=12" } }, - "node_modules/@endemolshinegroup/cosmiconfig-typescript-loader/node_modules/tslib": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.0.tgz", - "integrity": "sha512-d6xOpEDfsi2CZVlPQzGeux8XMwLT9hssAsaPYExaQMuYskwb+x1x7J371tWlbBdWHroy99KnVB6qIkUbs5X3UQ==", - "dev": true + "node_modules/@esbuild/android-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.17.19.tgz", + "integrity": "sha512-KBMWvEZooR7+kzY0BtbTQn0OAYY7CsiydT63pVEaPtVYF0hXbUaOyZog37DKxK7NF3XacBJOpYT4adIJh+avxA==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.17.19.tgz", + "integrity": "sha512-uUTTc4xGNDT7YSArp/zbtmbhO0uEEK9/ETW29Wk1thYUJBz3IVnvgEiEwEa9IeLyvnpKrWK64Utw2bgUmDveww==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.17.19.tgz", + "integrity": "sha512-80wEoCfF/hFKM6WE1FyBHc9SfUblloAWx6FJkFWTWiCoht9Mc0ARGEM47e67W9rI09YoUxJL68WHfDRYEAvOhg==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.17.19.tgz", + "integrity": "sha512-IJM4JJsLhRYr9xdtLytPLSH9k/oxR3boaUIYiHkAawtwNOXKE8KoU8tMvryogdcT8AU+Bflmh81Xn6Q0vTZbQw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.17.19.tgz", + "integrity": "sha512-pBwbc7DufluUeGdjSU5Si+P3SoMF5DQ/F/UmTSb8HXO80ZEAJmrykPyzo1IfNbAoaqw48YRpv8shwd1NoI0jcQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.17.19.tgz", + "integrity": "sha512-4lu+n8Wk0XlajEhbEffdy2xy53dpR06SlzvhGByyg36qJw6Kpfk7cp45DR/62aPH9mtJRmIyrXAS5UWBrJT6TQ==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.17.19.tgz", + "integrity": "sha512-cdmT3KxjlOQ/gZ2cjfrQOtmhG4HJs6hhvm3mWSRDPtZ/lP5oe8FWceS10JaSJC13GBd4eH/haHnqf7hhGNLerA==", + "cpu": [ + "arm" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.17.19.tgz", + "integrity": "sha512-ct1Tg3WGwd3P+oZYqic+YZF4snNl2bsnMKRkb3ozHmnM0dGWuxcPTTntAF6bOP0Sp4x0PjSF+4uHQ1xvxfRKqg==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.17.19.tgz", + "integrity": "sha512-w4IRhSy1VbsNxHRQpeGCHEmibqdTUx61Vc38APcsRbuVgK0OPEnQ0YD39Brymn96mOx48Y2laBQGqgZ0j9w6SQ==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.17.19.tgz", + "integrity": "sha512-2iAngUbBPMq439a+z//gE+9WBldoMp1s5GWsUSgqHLzLJ9WoZLZhpwWuym0u0u/4XmZ3gpHmzV84PonE+9IIdQ==", + "cpu": [ + "loong64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.17.19.tgz", + "integrity": "sha512-LKJltc4LVdMKHsrFe4MGNPp0hqDFA1Wpt3jE1gEyM3nKUvOiO//9PheZZHfYRfYl6AwdTH4aTcXSqBerX0ml4A==", + "cpu": [ + "mips64el" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.17.19.tgz", + "integrity": "sha512-/c/DGybs95WXNS8y3Ti/ytqETiW7EU44MEKuCAcpPto3YjQbyK3IQVKfF6nbghD7EcLUGl0NbiL5Rt5DMhn5tg==", + "cpu": [ + "ppc64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.17.19.tgz", + "integrity": "sha512-FC3nUAWhvFoutlhAkgHf8f5HwFWUL6bYdvLc/TTuxKlvLi3+pPzdZiFKSWz/PF30TB1K19SuCxDTI5KcqASJqA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.17.19.tgz", + "integrity": "sha512-IbFsFbxMWLuKEbH+7sTkKzL6NJmG2vRyy6K7JJo55w+8xDk7RElYn6xvXtDW8HCfoKBFK69f3pgBJSUSQPr+4Q==", + "cpu": [ + "s390x" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.17.19.tgz", + "integrity": "sha512-68ngA9lg2H6zkZcyp22tsVt38mlhWde8l3eJLWkyLrp4HwMUr3c1s/M2t7+kHIhvMjglIBrFpncX1SzMckomGw==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.17.19.tgz", + "integrity": "sha512-CwFq42rXCR8TYIjIfpXCbRX0rp1jo6cPIUPSaWwzbVI4aOfX96OXY8M6KNmtPcg7QjYeDmN+DD0Wp3LaBOLf4Q==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.17.19.tgz", + "integrity": "sha512-cnq5brJYrSZ2CF6c35eCmviIN3k3RczmHz8eYaVlNasVqsNY+JKohZU5MKmaOI+KkllCdzOKKdPs762VCPC20g==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.17.19.tgz", + "integrity": "sha512-vCRT7yP3zX+bKWFeP/zdS6SqdWB8OIpaRq/mbXQxTGHnIxspRtigpkUcDMlSCOejlHowLqII7K2JKevwyRP2rg==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.17.19.tgz", + "integrity": "sha512-yYx+8jwowUstVdorcMdNlzklLYhPxjniHWFKgRqH7IFlUEa0Umu3KuYplf1HUZZ422e3NU9F4LGb+4O0Kdcaag==", + "cpu": [ + "arm64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.17.19.tgz", + "integrity": "sha512-eggDKanJszUtCdlVs0RB+h35wNlb5v4TWEkq4vZcmVt5u/HiDZrTXe2bWFQUez3RgNHwx/x4sk5++4NSSicKkw==", + "cpu": [ + "ia32" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.17.19.tgz", + "integrity": "sha512-lAhycmKnVOuRYNtRtatQR1LPQf2oYCkRGkSFnseDAKPl8lu5SOsK/e1sXe5a0Pc5kHIHe6P2I/ilntNv2xf3cA==", + "cpu": [ + "x64" + ], + "dev": true, + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=12" + } }, "node_modules/@eslint-community/eslint-utils": { "version": "4.4.0", @@ -4541,6 +4883,18 @@ "node": ">=8" } }, + "node_modules/@jest/schemas": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", + "integrity": "sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==", + "dev": true, + "dependencies": { + "@sinclair/typebox": "^0.27.8" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, "node_modules/@jest/source-map": { "version": "26.6.2", "resolved": "https://registry.npmjs.org/@jest/source-map/-/source-map-26.6.2.tgz", @@ -4710,15 +5064,6 @@ "node": ">= 10.14.2" } }, - "node_modules/@jest/types/node_modules/@types/istanbul-reports": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.0.tgz", - "integrity": "sha512-nwKNbvnwJ2/mndE9ItP/zc2TCzw6uuodnF4EHYWD+gCQDVBuRQL5UzbZD0/ezy1iKsFU2ZQiDqg4M9dN4+wZgA==", - "dev": true, - "dependencies": { - "@types/istanbul-lib-report": "*" - } - }, "node_modules/@jest/types/node_modules/ansi-styles": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", @@ -4806,16 +5151,14 @@ "version": "3.1.0", "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz", "integrity": "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==", - "devOptional": true, "engines": { "node": ">=6.0.0" } }, "node_modules/@jridgewell/set-array": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz", - "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==", - "devOptional": true, + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", + "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==", "engines": { "node": ">=6.0.0" } @@ -4847,14 +5190,12 @@ "node_modules/@jridgewell/sourcemap-codec": { "version": "1.4.14", "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz", - "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==", - "devOptional": true + "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==" }, "node_modules/@jridgewell/trace-mapping": { - "version": "0.3.19", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.19.tgz", - "integrity": "sha512-kf37QtfW+Hwx/buWGMPcR60iF9ziHa6r/CZJIHbmcm4+0qrXiVdxegAH0F6yddEVQ7zdkjcGCgCzUu+BcbhQxw==", - "devOptional": true, + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", "dependencies": { "@jridgewell/resolve-uri": "^3.1.0", "@jridgewell/sourcemap-codec": "^1.4.14" @@ -4872,68 +5213,55 @@ "dev": true }, "node_modules/@lingui/babel-plugin-extract-messages": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@lingui/babel-plugin-extract-messages/-/babel-plugin-extract-messages-3.14.0.tgz", - "integrity": "sha512-4lcDgVdjYiObuFdDwnAG3jJxS+d3YLq4i7qywlHgjIqteKUH01S3paJRXhZaPvLGl56HarSq0kt8Pymxw8lOrA==", + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/babel-plugin-extract-messages/-/babel-plugin-extract-messages-4.11.3.tgz", + "integrity": "sha512-wLiquhtxE7qUmoKl4UStFI1XgrCkk9zwxc8z62LPpbutkyxO21B5k8fBUGlgWoKJaXbpvS8VIU8j2663q99JnQ==", "dev": true, - "dependencies": { - "@babel/generator": "^7.11.6", - "@babel/runtime": "^7.11.2", - "@lingui/conf": "^3.14.0", - "mkdirp": "^1.0.4" - }, "engines": { - "node": ">=10.0.0" + "node": ">=16.0.0" } }, "node_modules/@lingui/cli": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@lingui/cli/-/cli-3.14.0.tgz", - "integrity": "sha512-QZURsIf7A97tf28b/ffpeL0DekA6tBmcwnj4FBui1SbQqJw1d4IPg2bUM5VRn3/25vhqpi9Uhx5m9x7Vv8QfCQ==", - "dev": true, - "dependencies": { - "@babel/generator": "^7.11.6", - "@babel/parser": "^7.11.5", - "@babel/plugin-syntax-jsx": "^7.10.4", - "@babel/runtime": "^7.11.2", - "@babel/types": "^7.11.5", - "@lingui/babel-plugin-extract-messages": "^3.14.0", - "@lingui/conf": "^3.14.0", + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/cli/-/cli-4.11.3.tgz", + "integrity": "sha512-ykJLmQciK81I0Cd/iLg8dSpESV9Hnsbw5+G98IEAf4exvoUGRJ2UzkeNc/HeGx3D5Fg+TI8YNWwCbZ7NAOsDCQ==", + "dev": true, + "dependencies": { + "@babel/core": "^7.21.0", + "@babel/generator": "^7.21.1", + "@babel/parser": "^7.21.2", + "@babel/runtime": "^7.21.0", + "@babel/types": "^7.21.2", + "@lingui/babel-plugin-extract-messages": "4.11.3", + "@lingui/conf": "4.11.3", + "@lingui/core": "4.11.3", + "@lingui/format-po": "4.11.3", + "@lingui/message-utils": "4.11.3", "babel-plugin-macros": "^3.0.1", - "bcp-47": "^1.0.7", "chalk": "^4.1.0", "chokidar": "3.5.1", - "cli-table": "0.3.6", - "commander": "^6.1.0", - "date-fns": "^2.16.1", - "fs-extra": "^9.0.1", - "fuzzaldrin": "^2.1.0", + "cli-table": "^0.3.11", + "commander": "^10.0.0", + "convert-source-map": "^2.0.0", + "date-fns": "^3.6.0", + "esbuild": "^0.17.10", "glob": "^7.1.4", "inquirer": "^7.3.3", - "make-plural": "^6.2.2", - "messageformat-parser": "^4.1.3", "micromatch": "4.0.2", - "mkdirp": "^1.0.4", - "node-gettext": "^3.0.0", "normalize-path": "^3.0.0", "ora": "^5.1.0", - "papaparse": "^5.3.0", + "pathe": "^1.1.0", "pkg-up": "^3.1.0", - "plurals-cldr": "^1.0.4", - "pofile": "^1.1.0", - "pseudolocale": "^1.1.0", - "ramda": "^0.27.1" + "pofile": "^1.1.4", + "pseudolocale": "^2.0.0", + "ramda": "^0.27.1", + "source-map": "^0.8.0-beta.0" }, "bin": { - "lingui": "lingui.js" + "lingui": "dist/lingui.js" }, "engines": { - "node": ">=10.0.0" - }, - "peerDependencies": { - "@babel/core": "^7.0.0", - "babel-plugin-macros": "2 || 3", - "typescript": "2 || 3 || 4" + "node": ">=16.0.0" } }, "node_modules/@lingui/cli/node_modules/ansi-styles": { @@ -4985,6 +5313,12 @@ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true }, + "node_modules/@lingui/cli/node_modules/convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", + "dev": true + }, "node_modules/@lingui/cli/node_modules/has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", @@ -4994,11 +5328,17 @@ "node": ">=8" } }, - "node_modules/@lingui/cli/node_modules/make-plural": { - "version": "6.2.2", - "resolved": "https://registry.npmjs.org/make-plural/-/make-plural-6.2.2.tgz", - "integrity": "sha512-8iTuFioatnTTmb/YJjywkVIHLjcwkFD9Ms0JpxjEm9Mo8eQYkh1z+55dwv4yc1jQ8ftVBxWQbihvZL1DfzGGWA==", - "dev": true + "node_modules/@lingui/cli/node_modules/source-map": { + "version": "0.8.0-beta.0", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.8.0-beta.0.tgz", + "integrity": "sha512-2ymg6oRBpebeZi9UUNsgQ89bhx01TcTkmNTGnNO88imTmbSgy4nfujrgVEFKWpMTEGA11EDkTt7mqObTPdigIA==", + "dev": true, + "dependencies": { + "whatwg-url": "^7.0.0" + }, + "engines": { + "node": ">= 8" + } }, "node_modules/@lingui/cli/node_modules/supports-color": { "version": "7.2.0", @@ -5012,21 +5352,73 @@ "node": ">=8" } }, + "node_modules/@lingui/cli/node_modules/tr46": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-1.0.1.tgz", + "integrity": "sha512-dTpowEjclQ7Kgx5SdBkqRzVhERQXov8/l9Ft9dVM9fmg0W0KQSVaXX9T4i6twCPNtYiZM53lpSSUAwJbFPOHxA==", + "dev": true, + "dependencies": { + "punycode": "^2.1.0" + } + }, + "node_modules/@lingui/cli/node_modules/webidl-conversions": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-4.0.2.tgz", + "integrity": "sha512-YQ+BmxuTgd6UXZW3+ICGfyqRyHXVlD5GtQr5+qjiNW7bF0cqrzX500HVXPBOvgXb5YnzDd+h0zqyv61KUD7+Sg==", + "dev": true + }, + "node_modules/@lingui/cli/node_modules/whatwg-url": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-7.1.0.tgz", + "integrity": "sha512-WUu7Rg1DroM7oQvGWfOiAK21n74Gg+T4elXEQYkOhtyLeWiJFoOGLXPKI/9gzIie9CtwVLm8wtw6YJdKyxSjeg==", + "dev": true, + "dependencies": { + "lodash.sortby": "^4.7.0", + "tr46": "^1.0.1", + "webidl-conversions": "^4.0.2" + } + }, "node_modules/@lingui/conf": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@lingui/conf/-/conf-3.14.0.tgz", - "integrity": "sha512-5GMAbIRad9FavqYsfZCRAwjcOLzE7tONDJe9lSYE5SSJbbG01RI5kR5P0B84DUhTI6cGXau+1dAcP9K+JbEx+g==", + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/conf/-/conf-4.11.3.tgz", + "integrity": "sha512-KwUJDrbzlZEXmlmqttpB/Sd9hiIo0sqccsZaYTHzW/uULZT9T11aw/f6RcPLCVJeSKazg/7dJhR1cKlxKzvjKA==", "dev": true, "dependencies": { - "@babel/runtime": "^7.11.2", - "@endemolshinegroup/cosmiconfig-typescript-loader": "^3.0.2", + "@babel/runtime": "^7.20.13", "chalk": "^4.1.0", - "cosmiconfig": "^7.0.0", - "jest-validate": "^26.5.2", + "cosmiconfig": "^8.0.0", + "jest-validate": "^29.4.3", + "jiti": "^1.17.1", "lodash.get": "^4.4.2" }, "engines": { - "node": ">=10.0.0" + "node": ">=16.0.0" + } + }, + "node_modules/@lingui/conf/node_modules/@jest/types": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.6.3.tgz", + "integrity": "sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw==", + "dev": true, + "dependencies": { + "@jest/schemas": "^29.6.3", + "@types/istanbul-lib-coverage": "^2.0.0", + "@types/istanbul-reports": "^3.0.0", + "@types/node": "*", + "@types/yargs": "^17.0.8", + "chalk": "^4.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@lingui/conf/node_modules/@types/yargs": { + "version": "17.0.33", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.33.tgz", + "integrity": "sha512-WpxBCKWPLr4xSsHgz511rFJAM+wS28w2zEO1QDNY5zM/S8ok70NNfztH0xwhqKyaK0OHCbN98LDAZuy1ctxDkA==", + "dev": true, + "dependencies": { + "@types/yargs-parser": "*" } }, "node_modules/@lingui/conf/node_modules/ansi-styles": { @@ -5044,6 +5436,12 @@ "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, + "node_modules/@lingui/conf/node_modules/argparse": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", + "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", + "dev": true + }, "node_modules/@lingui/conf/node_modules/chalk": { "version": "4.1.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", @@ -5078,6 +5476,32 @@ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true }, + "node_modules/@lingui/conf/node_modules/cosmiconfig": { + "version": "8.3.6", + "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-8.3.6.tgz", + "integrity": "sha512-kcZ6+W5QzcJ3P1Mt+83OUv/oHFqZHIx8DuxG6eZ5RGMERoLqp4BuGjhHLYGK+Kf5XVkQvqBSmAy/nGWN3qDgEA==", + "dev": true, + "dependencies": { + "import-fresh": "^3.3.0", + "js-yaml": "^4.1.0", + "parse-json": "^5.2.0", + "path-type": "^4.0.0" + }, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/d-fischer" + }, + "peerDependencies": { + "typescript": ">=4.9.5" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, "node_modules/@lingui/conf/node_modules/has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", @@ -5087,6 +5511,76 @@ "node": ">=8" } }, + "node_modules/@lingui/conf/node_modules/jest-get-type": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/jest-get-type/-/jest-get-type-29.6.3.tgz", + "integrity": "sha512-zrteXnqYxfQh7l5FHyL38jL39di8H8rHoecLH3JNxH3BwOrBsNeabdap5e0I23lD4HHI8W5VFBZqG4Eaq5LNcw==", + "dev": true, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@lingui/conf/node_modules/jest-validate": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-29.7.0.tgz", + "integrity": "sha512-ZB7wHqaRGVw/9hST/OuFUReG7M8vKeq0/J2egIGLdvjHCmYqGARhzXmtgi+gVeZ5uXFF219aOc3Ls2yLg27tkw==", + "dev": true, + "dependencies": { + "@jest/types": "^29.6.3", + "camelcase": "^6.2.0", + "chalk": "^4.0.0", + "jest-get-type": "^29.6.3", + "leven": "^3.1.0", + "pretty-format": "^29.7.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@lingui/conf/node_modules/js-yaml": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", + "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", + "dev": true, + "dependencies": { + "argparse": "^2.0.1" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, + "node_modules/@lingui/conf/node_modules/pretty-format": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-29.7.0.tgz", + "integrity": "sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ==", + "dev": true, + "dependencies": { + "@jest/schemas": "^29.6.3", + "ansi-styles": "^5.0.0", + "react-is": "^18.0.0" + }, + "engines": { + "node": "^14.15.0 || ^16.10.0 || >=18.0.0" + } + }, + "node_modules/@lingui/conf/node_modules/pretty-format/node_modules/ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/@lingui/conf/node_modules/react-is": { + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", + "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", + "dev": true + }, "node_modules/@lingui/conf/node_modules/supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", @@ -5099,77 +5593,121 @@ "node": ">=8" } }, + "node_modules/@lingui/conf/node_modules/typescript": { + "version": "5.5.4", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.5.4.tgz", + "integrity": "sha512-Mtq29sKDAEYP7aljRgtPOpTvOfbwRWlS6dPRzwjdE+C0R4brX/GUyhHSecbHMFLNBLcJIPt9nl9yG5TZ1weH+Q==", + "dev": true, + "optional": true, + "peer": true, + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, "node_modules/@lingui/core": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@lingui/core/-/core-3.14.0.tgz", - "integrity": "sha512-ertREq9oi9B/umxpd/pInm9uFO8FLK2/0FXfDmMqvH5ydswWn/c9nY5YO4W1h4/8LWO45mewypOIyjoue4De1w==", + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/core/-/core-4.11.3.tgz", + "integrity": "sha512-IjJxn0Kvzv+ICnGlMqn8wRIQLikCJVrolb1oyi6GqtbiuPiwKYeU0D6Hbe146lMaTN8juc3tOCBS+Fr02XqFIQ==", "dependencies": { - "@babel/runtime": "^7.11.2", - "make-plural": "^6.2.2", - "messageformat-parser": "^4.1.3" + "@babel/runtime": "^7.20.13", + "@lingui/message-utils": "4.11.3", + "unraw": "^3.0.0" }, "engines": { - "node": ">=10.0.0" + "node": ">=16.0.0" } }, - "node_modules/@lingui/core/node_modules/make-plural": { - "version": "6.2.2", - "resolved": "https://registry.npmjs.org/make-plural/-/make-plural-6.2.2.tgz", - "integrity": "sha512-8iTuFioatnTTmb/YJjywkVIHLjcwkFD9Ms0JpxjEm9Mo8eQYkh1z+55dwv4yc1jQ8ftVBxWQbihvZL1DfzGGWA==" + "node_modules/@lingui/format-po": { + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/format-po/-/format-po-4.11.3.tgz", + "integrity": "sha512-RgEkoo0aEAk7X1xGrApcpqkz6GLdzkRLGw2jo3mmCVR0P7P9sWbJL/cd01GmR+HzAOo8Zx5oIayaKh9iyJS8tA==", + "dev": true, + "dependencies": { + "@lingui/conf": "4.11.3", + "@lingui/message-utils": "4.11.3", + "date-fns": "^3.6.0", + "pofile": "^1.1.4" + }, + "engines": { + "node": ">=16.0.0" + } }, "node_modules/@lingui/loader": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@lingui/loader/-/loader-3.14.0.tgz", - "integrity": "sha512-FH14MexRLM8tBgSL1oK5dbaUBbY0P85CSLTNwFqAtFFj8K8wWxfdq4+rIkp/kSD+eggKNDYV4G89N9/3bsm3gQ==", + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/loader/-/loader-4.11.3.tgz", + "integrity": "sha512-K0482e0d+KRlljylkOAp6DkOKHboevAqR2nRRipwa8BGV1nJsnSwkvrlny+/OazZK0Dvr7w6tmBODx8KS318Ng==", "dev": true, "dependencies": { - "@babel/runtime": "^7.11.2", - "@lingui/cli": "^3.14.0", - "@lingui/conf": "^3.14.0", - "loader-utils": "^2.0.0", - "ramda": "^0.27.1" + "@babel/runtime": "^7.20.13", + "@lingui/cli": "4.11.3", + "@lingui/conf": "4.11.3" }, "engines": { - "node": ">=10.0.0" + "node": ">=16.0.0" }, "peerDependencies": { - "webpack": "^4.0.0 || ^5.0.0" + "webpack": "^5.0.0" } }, "node_modules/@lingui/macro": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@lingui/macro/-/macro-3.14.0.tgz", - "integrity": "sha512-NxTRrhrZ/cUO9PX/4vWys90Ku58+ExxHuE30IuDnnDldWhWlOdycmjDt9tB+yIiUdFym/veSxBs+h114FzG5mA==", + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/macro/-/macro-4.11.3.tgz", + "integrity": "sha512-D0me8ZRtH0ylSavhKZu0FYf5mJ1y6kDMMPjYVDyiT5ooOI/5jjv9LIAqrdYGCBygnwsxOG1dzDw6+3s5GTs+Bg==", "dev": true, "dependencies": { - "@babel/runtime": "^7.11.2", - "@lingui/conf": "^3.14.0", - "ramda": "^0.27.1" + "@babel/runtime": "^7.20.13", + "@babel/types": "^7.20.7", + "@lingui/conf": "4.11.3", + "@lingui/core": "4.11.3", + "@lingui/message-utils": "4.11.3" }, "engines": { - "node": ">=10.0.0" + "node": ">=16.0.0" }, "peerDependencies": { - "@lingui/core": "^3.13.0", - "@lingui/react": "^3.13.0", - "babel-plugin-macros": "2 || 3" + "@lingui/react": "^4.0.0", + "babel-plugin-macros": "2 || 3" + } + }, + "node_modules/@lingui/message-utils": { + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/message-utils/-/message-utils-4.11.3.tgz", + "integrity": "sha512-ZSw3OoKbknOw3nSrqt194g2F8r0guKow9csb46zlL7zX/yOWCaj767wvSvMoglZtVvurfQs4NPv2cohYlWORNw==", + "dependencies": { + "@messageformat/parser": "^5.0.0", + "js-sha256": "^0.10.1" + }, + "engines": { + "node": ">=16.0.0" } }, "node_modules/@lingui/react": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@lingui/react/-/react-3.14.0.tgz", - "integrity": "sha512-ow9Mtru7f0T2S9AwnPWRejppcucCW0LmoDR3P4wqHjL+eH5f8a6nxd2doxGieC91/2i4qqW88y4K/zXJxwRSQw==", + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/react/-/react-4.11.3.tgz", + "integrity": "sha512-FuorwDsz5zDpUNpyj7J8ZKqJrrVxOz1EtQ3aJGJsmnTtVO01N3nR3ckMzpYvZ71XXdDEvhUC9ihmiKbFvpaZ/w==", "dependencies": { - "@babel/runtime": "^7.11.2", - "@lingui/core": "^3.14.0" + "@babel/runtime": "^7.20.13", + "@lingui/core": "4.11.3" }, "engines": { - "node": ">=10.0.0" + "node": ">=16.0.0" }, "peerDependencies": { "react": "^16.8.0 || ^17.0.0 || ^18.0.0" } }, + "node_modules/@messageformat/parser": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@messageformat/parser/-/parser-5.1.0.tgz", + "integrity": "sha512-jKlkls3Gewgw6qMjKZ9SFfHUpdzEVdovKFtW1qRhJ3WI4FW5R/NnGDqr8SDGz+krWDO3ki94boMmQvGke1HwUQ==", + "dependencies": { + "moo": "^0.5.1" + } + }, "node_modules/@nicolo-ribaudo/chokidar-2": { "version": "2.1.8-no-fsevents.3", "resolved": "https://registry.npmjs.org/@nicolo-ribaudo/chokidar-2/-/chokidar-2-2.1.8-no-fsevents.3.tgz", @@ -5285,6 +5823,12 @@ "integrity": "sha512-Vvn3zZrhQZkkBE8LSuW3em98c0FwgO4nxzv6OdSxPKJIEKY2bGbHn+mhGIPerzI4twdxaP8/0+06HBpwf345Lw==", "dev": true }, + "node_modules/@sinclair/typebox": { + "version": "0.27.8", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.8.tgz", + "integrity": "sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==", + "dev": true + }, "node_modules/@sinonjs/commons": { "version": "1.8.2", "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-1.8.2.tgz", @@ -5738,30 +6282,10 @@ "resolved": "https://registry.npmjs.org/@types/d3-time-format/-/d3-time-format-2.1.0.tgz", "integrity": "sha512-/myT3I7EwlukNOX2xVdMzb8FRgNzRMpsZddwst9Ld/VFe6LyJyRp0s32l/V9XoUzk+Gqu56F/oGk6507+8BxrA==" }, - "node_modules/@types/eslint": { - "version": "8.4.5", - "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.4.5.tgz", - "integrity": "sha512-dhsC09y1gpJWnK+Ff4SGvCuSnk9DaU0BJZSzOwa6GVSg65XtTugLBITDAAzRU5duGBoXBHpdR/9jHGxJjNflJQ==", - "dev": true, - "dependencies": { - "@types/estree": "*", - "@types/json-schema": "*" - } - }, - "node_modules/@types/eslint-scope": { - "version": "3.7.4", - "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.4.tgz", - "integrity": "sha512-9K4zoImiZc3HlIp6AVUDE4CWYx22a+lhSZMYNpbjW04+YF0KWj4pJXnEMjdnFTiQibFFmElcsasJXDbdI/EPhA==", - "dev": true, - "dependencies": { - "@types/eslint": "*", - "@types/estree": "*" - } - }, "node_modules/@types/estree": { - "version": "0.0.51", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-0.0.51.tgz", - "integrity": "sha512-CuPgU6f3eT/XgKKPqKd/gLZV1Xmvf1a2R5POBOGQa6uv82xpls89HU5zKeVoyR8XzHd1RGNOlQlvUe3CFkjWNQ==", + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz", + "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==", "dev": true }, "node_modules/@types/express": { @@ -5841,6 +6365,15 @@ "@types/istanbul-lib-coverage": "*" } }, + "node_modules/@types/istanbul-reports": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", + "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", + "dev": true, + "dependencies": { + "@types/istanbul-lib-report": "*" + } + }, "node_modules/@types/jest": { "version": "26.0.15", "resolved": "https://registry.npmjs.org/@types/jest/-/jest-26.0.15.tgz", @@ -6723,148 +7256,148 @@ } }, "node_modules/@webassemblyjs/ast": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.11.1.tgz", - "integrity": "sha512-ukBh14qFLjxTQNTXocdyksN5QdM28S1CxHt2rdskFyL+xFV7VremuBLVbmCePj+URalXBENx/9Lm7lnhihtCSw==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.12.1.tgz", + "integrity": "sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==", "dev": true, "dependencies": { - "@webassemblyjs/helper-numbers": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1" + "@webassemblyjs/helper-numbers": "1.11.6", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6" } }, "node_modules/@webassemblyjs/floating-point-hex-parser": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.11.1.tgz", - "integrity": "sha512-iGRfyc5Bq+NnNuX8b5hwBrRjzf0ocrJPI6GWFodBFzmFnyvrQ83SHKhmilCU/8Jv67i4GJZBMhEzltxzcNagtQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.11.6.tgz", + "integrity": "sha512-ejAj9hfRJ2XMsNHk/v6Fu2dGS+i4UaXBXGemOfQ/JfQ6mdQg/WXtwleQRLLS4OvfDhv8rYnVwH27YJLMyYsxhw==", "dev": true }, "node_modules/@webassemblyjs/helper-api-error": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.11.1.tgz", - "integrity": "sha512-RlhS8CBCXfRUR/cwo2ho9bkheSXG0+NwooXcc3PAILALf2QLdFyj7KGsKRbVc95hZnhnERon4kW/D3SZpp6Tcg==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.11.6.tgz", + "integrity": "sha512-o0YkoP4pVu4rN8aTJgAyj9hC2Sv5UlkzCHhxqWj8butaLvnpdc2jOwh4ewE6CX0txSfLn/UYaV/pheS2Txg//Q==", "dev": true }, "node_modules/@webassemblyjs/helper-buffer": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.11.1.tgz", - "integrity": "sha512-gwikF65aDNeeXa8JxXa2BAk+REjSyhrNC9ZwdT0f8jc4dQQeDQ7G4m0f2QCLPJiMTTO6wfDmRmj/pW0PsUvIcA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.12.1.tgz", + "integrity": "sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==", "dev": true }, "node_modules/@webassemblyjs/helper-numbers": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-numbers/-/helper-numbers-1.11.1.tgz", - "integrity": "sha512-vDkbxiB8zfnPdNK9Rajcey5C0w+QJugEglN0of+kmO8l7lDb77AnlKYQF7aarZuCrv+l0UvqL+68gSDr3k9LPQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-numbers/-/helper-numbers-1.11.6.tgz", + "integrity": "sha512-vUIhZ8LZoIWHBohiEObxVm6hwP034jwmc9kuq5GdHZH0wiLVLIPcMCdpJzG4C11cHoQ25TFIQj9kaVADVX7N3g==", "dev": true, "dependencies": { - "@webassemblyjs/floating-point-hex-parser": "1.11.1", - "@webassemblyjs/helper-api-error": "1.11.1", + "@webassemblyjs/floating-point-hex-parser": "1.11.6", + "@webassemblyjs/helper-api-error": "1.11.6", "@xtuc/long": "4.2.2" } }, "node_modules/@webassemblyjs/helper-wasm-bytecode": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.11.1.tgz", - "integrity": "sha512-PvpoOGiJwXeTrSf/qfudJhwlvDQxFgelbMqtq52WWiXC6Xgg1IREdngmPN3bs4RoO83PnL/nFrxucXj1+BX62Q==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.11.6.tgz", + "integrity": "sha512-sFFHKwcmBprO9e7Icf0+gddyWYDViL8bpPjJJl0WHxCdETktXdmtWLGVzoHbqUcY4Be1LkNfwTmXOJUFZYSJdA==", "dev": true }, "node_modules/@webassemblyjs/helper-wasm-section": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.11.1.tgz", - "integrity": "sha512-10P9No29rYX1j7F3EVPX3JvGPQPae+AomuSTPiF9eBQeChHI6iqjMIwR9JmOJXwpnn/oVGDk7I5IlskuMwU/pg==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.12.1.tgz", + "integrity": "sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==", "dev": true, "dependencies": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-buffer": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/wasm-gen": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/wasm-gen": "1.12.1" } }, "node_modules/@webassemblyjs/ieee754": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.11.1.tgz", - "integrity": "sha512-hJ87QIPtAMKbFq6CGTkZYJivEwZDbQUgYd3qKSadTNOhVY7p+gfP6Sr0lLRVTaG1JjFj+r3YchoqRYxNH3M0GQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.11.6.tgz", + "integrity": "sha512-LM4p2csPNvbij6U1f19v6WR56QZ8JcHg3QIJTlSwzFcmx6WSORicYj6I63f9yU1kEUtrpG+kjkiIAkevHpDXrg==", "dev": true, "dependencies": { "@xtuc/ieee754": "^1.2.0" } }, "node_modules/@webassemblyjs/leb128": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.11.1.tgz", - "integrity": "sha512-BJ2P0hNZ0u+Th1YZXJpzW6miwqQUGcIHT1G/sf72gLVD9DZ5AdYTqPNbHZh6K1M5VmKvFXwGSWZADz+qBWxeRw==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.11.6.tgz", + "integrity": "sha512-m7a0FhE67DQXgouf1tbN5XQcdWoNgaAuoULHIfGFIEVKA6tu/edls6XnIlkmS6FrXAquJRPni3ZZKjw6FSPjPQ==", "dev": true, "dependencies": { "@xtuc/long": "4.2.2" } }, "node_modules/@webassemblyjs/utf8": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.11.1.tgz", - "integrity": "sha512-9kqcxAEdMhiwQkHpkNiorZzqpGrodQQ2IGrHHxCy+Ozng0ofyMA0lTqiLkVs1uzTRejX+/O0EOT7KxqVPuXosQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.11.6.tgz", + "integrity": "sha512-vtXf2wTQ3+up9Zsg8sa2yWiQpzSsMyXj0qViVP6xKGCUT8p8YJ6HqI7l5eCnWx1T/FYdsv07HQs2wTFbbof/RA==", "dev": true }, "node_modules/@webassemblyjs/wasm-edit": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.11.1.tgz", - "integrity": "sha512-g+RsupUC1aTHfR8CDgnsVRVZFJqdkFHpsHMfJuWQzWU3tvnLC07UqHICfP+4XyL2tnr1amvl1Sdp06TnYCmVkA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.12.1.tgz", + "integrity": "sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==", "dev": true, "dependencies": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-buffer": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/helper-wasm-section": "1.11.1", - "@webassemblyjs/wasm-gen": "1.11.1", - "@webassemblyjs/wasm-opt": "1.11.1", - "@webassemblyjs/wasm-parser": "1.11.1", - "@webassemblyjs/wast-printer": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/helper-wasm-section": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-opt": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1", + "@webassemblyjs/wast-printer": "1.12.1" } }, "node_modules/@webassemblyjs/wasm-gen": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.11.1.tgz", - "integrity": "sha512-F7QqKXwwNlMmsulj6+O7r4mmtAlCWfO/0HdgOxSklZfQcDu0TpLiD1mRt/zF25Bk59FIjEuGAIyn5ei4yMfLhA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.12.1.tgz", + "integrity": "sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==", "dev": true, "dependencies": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/ieee754": "1.11.1", - "@webassemblyjs/leb128": "1.11.1", - "@webassemblyjs/utf8": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/ieee754": "1.11.6", + "@webassemblyjs/leb128": "1.11.6", + "@webassemblyjs/utf8": "1.11.6" } }, "node_modules/@webassemblyjs/wasm-opt": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.11.1.tgz", - "integrity": "sha512-VqnkNqnZlU5EB64pp1l7hdm3hmQw7Vgqa0KF/KCNO9sIpI6Fk6brDEiX+iCOYrvMuBWDws0NkTOxYEb85XQHHw==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.12.1.tgz", + "integrity": "sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==", "dev": true, "dependencies": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-buffer": "1.11.1", - "@webassemblyjs/wasm-gen": "1.11.1", - "@webassemblyjs/wasm-parser": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1" } }, "node_modules/@webassemblyjs/wasm-parser": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.11.1.tgz", - "integrity": "sha512-rrBujw+dJu32gYB7/Lup6UhdkPx9S9SnobZzRVL7VcBH9Bt9bCBLEuX/YXOOtBsOZ4NQrRykKhffRWHvigQvOA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.12.1.tgz", + "integrity": "sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==", "dev": true, "dependencies": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-api-error": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/ieee754": "1.11.1", - "@webassemblyjs/leb128": "1.11.1", - "@webassemblyjs/utf8": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-api-error": "1.11.6", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/ieee754": "1.11.6", + "@webassemblyjs/leb128": "1.11.6", + "@webassemblyjs/utf8": "1.11.6" } }, "node_modules/@webassemblyjs/wast-printer": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.11.1.tgz", - "integrity": "sha512-IQboUWM4eKzWW+N/jij2sRatKMh99QEelo3Eb2q0qXkvPRISAj8Qxtmw5itwqK+TTkBuUIE45AxYPToqPtL5gg==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.12.1.tgz", + "integrity": "sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==", "dev": true, "dependencies": { - "@webassemblyjs/ast": "1.11.1", + "@webassemblyjs/ast": "1.12.1", "@xtuc/long": "4.2.2" } }, @@ -7040,10 +7573,10 @@ "node": ">=0.4.0" } }, - "node_modules/acorn-import-assertions": { - "version": "1.8.0", - "resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.8.0.tgz", - "integrity": "sha512-m7VZ3jwz4eK6A4Vtt8Ew1/mNbP24u0FhdyfA7fSvnJR6LMdfOYnmuIrrJAgrYfYJ10F/otaHTtrtrtmHdMNzEw==", + "node_modules/acorn-import-attributes": { + "version": "1.9.5", + "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz", + "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==", "dev": true, "peerDependencies": { "acorn": "^8" @@ -7500,12 +8033,6 @@ "graphql": "^15.3.0 || ^16.0.0" } }, - "node_modules/arg": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", - "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", - "dev": true - }, "node_modules/argparse": { "version": "1.0.10", "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", @@ -7695,15 +8222,6 @@ "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=", "dev": true }, - "node_modules/at-least-node": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/at-least-node/-/at-least-node-1.0.0.tgz", - "integrity": "sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg==", - "dev": true, - "engines": { - "node": ">= 4.0.0" - } - }, "node_modules/atob": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz", @@ -8045,17 +8563,6 @@ "integrity": "sha1-3DQxT05nkxgJP8dgJyUl+UvyXBY=", "dev": true }, - "node_modules/bcp-47": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/bcp-47/-/bcp-47-1.0.8.tgz", - "integrity": "sha512-Y9y1QNBBtYtv7hcmoX0tR+tUNSFZGZ6OL6vKPObq8BbOhkCoyayF6ogfLTgAli/KuAEbsYHYUNq2AQuY6IuLag==", - "dev": true, - "dependencies": { - "is-alphabetical": "^1.0.0", - "is-alphanumerical": "^1.0.0", - "is-decimal": "^1.0.0" - } - }, "node_modules/big.js": { "version": "5.2.2", "resolved": "https://registry.npmjs.org/big.js/-/big.js-5.2.2.tgz", @@ -8092,9 +8599,9 @@ "dev": true }, "node_modules/body-parser": { - "version": "1.20.2", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", - "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", + "version": "1.20.3", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", + "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", "dependencies": { "bytes": "3.1.2", "content-type": "~1.0.5", @@ -8104,7 +8611,7 @@ "http-errors": "2.0.0", "iconv-lite": "0.4.24", "on-finished": "2.4.1", - "qs": "6.11.0", + "qs": "6.13.0", "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" @@ -8122,6 +8629,20 @@ "node": ">= 0.8" } }, + "node_modules/body-parser/node_modules/qs": { + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz", + "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==", + "dependencies": { + "side-channel": "^1.0.6" + }, + "engines": { + "node": ">=0.6" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/bonjour-service": { "version": "1.0.12", "resolved": "https://registry.npmjs.org/bonjour-service/-/bonjour-service-1.0.12.tgz", @@ -8175,9 +8696,9 @@ "dev": true }, "node_modules/browserslist": { - "version": "4.22.2", - "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.22.2.tgz", - "integrity": "sha512-0UgcrvQmBDvZHFGdYUehrCNIazki7/lUP3kkoi/r3YB2amZbFM9J43ZRkJTXBUZK4gmx56+Sqk9+Vs9mwZx9+A==", + "version": "4.23.3", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.23.3.tgz", + "integrity": "sha512-btwCFJVjI4YWDNfau8RhZ+B1Q/VLoUITrm3RlP6y1tYGWIOa+InuYiRGXUBXo8nA1qKmHMyLB/iVQg5TT4eFoA==", "devOptional": true, "funding": [ { @@ -8194,10 +8715,10 @@ } ], "dependencies": { - "caniuse-lite": "^1.0.30001565", - "electron-to-chromium": "^1.4.601", - "node-releases": "^2.0.14", - "update-browserslist-db": "^1.0.13" + "caniuse-lite": "^1.0.30001646", + "electron-to-chromium": "^1.5.4", + "node-releases": "^2.0.18", + "update-browserslist-db": "^1.1.0" }, "bin": { "browserslist": "cli.js" @@ -8266,12 +8787,21 @@ } }, "node_modules/call-bind": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", - "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.7.tgz", + "integrity": "sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==", "dependencies": { - "function-bind": "^1.1.1", - "get-intrinsic": "^1.0.2" + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "set-function-length": "^1.2.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, "node_modules/callsites": { @@ -8311,9 +8841,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001572", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001572.tgz", - "integrity": "sha512-1Pbh5FLmn5y4+QhNyJE9j3/7dK44dGB83/ZMjv/qJk86TvDbjk0LosiZo0i0WB0Vx607qMX9jYrn1VLHCkN4rw==", + "version": "1.0.30001653", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001653.tgz", + "integrity": "sha512-XGWQVB8wFQ2+9NZwZ10GxTYC5hk0Fa+q8cSkr0tgvMhYhMHP/QC+WTgrePMDBWiWc/pV+1ik82Al20XOK25Gcw==", "devOptional": true, "funding": [ { @@ -8515,9 +9045,9 @@ } }, "node_modules/cli-table": { - "version": "0.3.6", - "resolved": "https://registry.npmjs.org/cli-table/-/cli-table-0.3.6.tgz", - "integrity": "sha512-ZkNZbnZjKERTY5NwC2SeMeLeifSPq/pubeRoTpdr3WchLlnZg6hEgvHkK5zL7KNFdd9PmHN8lxrENUwI3cE8vQ==", + "version": "0.3.11", + "resolved": "https://registry.npmjs.org/cli-table/-/cli-table-0.3.11.tgz", + "integrity": "sha512-IqLQi4lO0nIB4tcdTpN4LCB9FI3uqrJZK7RC515EnhZ6qBaglkIgICb1wjeAqpdoOabm1+SuQtkXIPdYC93jhQ==", "dev": true, "dependencies": { "colors": "1.0.3" @@ -8644,12 +9174,12 @@ } }, "node_modules/commander": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/commander/-/commander-6.2.1.tgz", - "integrity": "sha512-U7VdrJFnJgo4xjrHpTzu0yrHPGImdsmD95ZlgYSEajAn2JKzDhDTPG9kBTefmObL2w/ngeZnilk+OV9CG3d7UA==", + "version": "10.0.1", + "resolved": "https://registry.npmjs.org/commander/-/commander-10.0.1.tgz", + "integrity": "sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug==", "dev": true, "engines": { - "node": ">= 6" + "node": ">=14" } }, "node_modules/commondir": { @@ -8849,12 +9379,6 @@ "node": ">=10" } }, - "node_modules/create-require": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz", - "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==", - "dev": true - }, "node_modules/cross-spawn": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", @@ -9398,12 +9922,13 @@ } }, "node_modules/date-fns": { - "version": "2.16.1", - "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-2.16.1.tgz", - "integrity": "sha512-sAJVKx/FqrLYHAQeN7VpJrPhagZc9R4ImZIWYRFZaaohR3KzmuK88touwsSwSVT8Qcbd4zoDsnGfX4GFB4imyQ==", + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-3.6.0.tgz", + "integrity": "sha512-fRHTG8g/Gif+kSh50gaGEdToemgfj74aRX3swtiouboip5JDLAyDE9F11nHMIcvOaXeOC6D7SpNhi7uFyB7Uww==", "dev": true, - "engines": { - "node": ">=0.11" + "funding": { + "type": "github", + "url": "https://github.com/sponsors/kossnocorp" } }, "node_modules/debounce": { @@ -9554,6 +10079,22 @@ "clone": "^1.0.2" } }, + "node_modules/define-data-property": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", + "integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==", + "dependencies": { + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "gopd": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/define-lazy-prop": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/define-lazy-prop/-/define-lazy-prop-2.0.0.tgz", @@ -9713,15 +10254,6 @@ "wrappy": "1" } }, - "node_modules/diff": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", - "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", - "dev": true, - "engines": { - "node": ">=0.3.1" - } - }, "node_modules/diff-sequences": { "version": "26.6.2", "resolved": "https://registry.npmjs.org/diff-sequences/-/diff-sequences-26.6.2.tgz", @@ -9926,9 +10458,9 @@ "integrity": "sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0=" }, "node_modules/electron-to-chromium": { - "version": "1.4.616", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.616.tgz", - "integrity": "sha512-1n7zWYh8eS0L9Uy+GskE0lkBUNK83cXTVJI0pU3mGprFsbfSdAc15VTFbo+A+Bq4pwstmL30AVcEU3Fo463lNg==", + "version": "1.5.13", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.13.tgz", + "integrity": "sha512-lbBcvtIJ4J6sS4tb5TLp1b4LyfCdMkwStzXPyAgVgTRAsep4bvrAGaBOP7ZJtQMNJpSQ9SqG4brWOroNaQtm7Q==", "devOptional": true }, "node_modules/emittery": { @@ -9973,9 +10505,9 @@ } }, "node_modules/enhanced-resolve": { - "version": "5.10.0", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.10.0.tgz", - "integrity": "sha512-T0yTFjdpldGY8PmuXXR0PyQ1ufZpEGiHVrp7zHKB7jdR4qlmZHhONVM5AQOAWXuF/w3dnHbEQVrNptJgt7F+cQ==", + "version": "5.17.1", + "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.17.1.tgz", + "integrity": "sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg==", "dev": true, "dependencies": { "graceful-fs": "^4.2.4", @@ -10068,10 +10600,29 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/es-define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.0.tgz", + "integrity": "sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==", + "dependencies": { + "get-intrinsic": "^1.2.4" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-errors": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", + "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", + "engines": { + "node": ">= 0.4" + } + }, "node_modules/es-module-lexer": { - "version": "0.9.3", - "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-0.9.3.tgz", - "integrity": "sha512-1HQ2M2sPtxwnvOvT1ZClHyQDiggdNjURWpY2we6aMKCQiUVxTmVs2UYPLIrD84sS+kMdUwfBSylbJPwNnBrnHQ==", + "version": "1.5.4", + "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.5.4.tgz", + "integrity": "sha512-MVNK56NiMrOwitFB7cqDwq0CQutbw+0BvLshJSse0MUNU+y1FC3bUS/AQg7oUng+/wKrrki7JfmwtVHkVfPLlw==", "dev": true }, "node_modules/es-shim-unscopables": { @@ -10097,10 +10648,47 @@ "node": ">= 0.4" } }, + "node_modules/esbuild": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.17.19.tgz", + "integrity": "sha512-XQ0jAPFkK/u3LcVRcvVHQcTIqD6E2H1fvZMA5dQPSOWb3suUbWbfbRf94pjc0bNzRYLfIrDRQXr7X+LHIm5oHw==", + "dev": true, + "hasInstallScript": true, + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=12" + }, + "optionalDependencies": { + "@esbuild/android-arm": "0.17.19", + "@esbuild/android-arm64": "0.17.19", + "@esbuild/android-x64": "0.17.19", + "@esbuild/darwin-arm64": "0.17.19", + "@esbuild/darwin-x64": "0.17.19", + "@esbuild/freebsd-arm64": "0.17.19", + "@esbuild/freebsd-x64": "0.17.19", + "@esbuild/linux-arm": "0.17.19", + "@esbuild/linux-arm64": "0.17.19", + "@esbuild/linux-ia32": "0.17.19", + "@esbuild/linux-loong64": "0.17.19", + "@esbuild/linux-mips64el": "0.17.19", + "@esbuild/linux-ppc64": "0.17.19", + "@esbuild/linux-riscv64": "0.17.19", + "@esbuild/linux-s390x": "0.17.19", + "@esbuild/linux-x64": "0.17.19", + "@esbuild/netbsd-x64": "0.17.19", + "@esbuild/openbsd-x64": "0.17.19", + "@esbuild/sunos-x64": "0.17.19", + "@esbuild/win32-arm64": "0.17.19", + "@esbuild/win32-ia32": "0.17.19", + "@esbuild/win32-x64": "0.17.19" + } + }, "node_modules/escalade": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", - "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.2.tgz", + "integrity": "sha512-ErCHMCae19vR8vQGe50xIsVomy19rg6gFu3+r3jkEO46suLMWBksvVyoGgQV+jOfl84ZSOSlmv6Gxa89PmTGmA==", "devOptional": true, "engines": { "node": ">=6" @@ -10842,7 +11430,7 @@ "node_modules/etag": { "version": "1.8.1", "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", - "integrity": "sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc=", + "integrity": "sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==", "engines": { "node": ">= 0.6" } @@ -11043,36 +11631,36 @@ "dev": true }, "node_modules/express": { - "version": "4.19.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", - "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", + "version": "4.20.0", + "resolved": "https://registry.npmjs.org/express/-/express-4.20.0.tgz", + "integrity": "sha512-pLdae7I6QqShF5PnNTCVn4hI91Dx0Grkn2+IAsMTgMIKuQVte2dN9PeGSSAME2FR8anOhVA62QDIUaWVfEXVLw==", "dependencies": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.2", + "body-parser": "1.20.3", "content-disposition": "0.5.4", "content-type": "~1.0.4", "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "etag": "~1.8.1", "finalhandler": "1.2.0", "fresh": "0.5.2", "http-errors": "2.0.0", - "merge-descriptors": "1.0.1", + "merge-descriptors": "1.0.3", "methods": "~1.1.2", "on-finished": "2.4.1", "parseurl": "~1.3.3", - "path-to-regexp": "0.1.7", + "path-to-regexp": "0.1.10", "proxy-addr": "~2.0.7", "qs": "6.11.0", "range-parser": "~1.2.1", "safe-buffer": "5.2.1", - "send": "0.18.0", - "serve-static": "1.15.0", + "send": "0.19.0", + "serve-static": "1.16.0", "setprototypeof": "1.2.0", "statuses": "2.0.1", "type-is": "~1.6.18", @@ -11091,6 +11679,14 @@ "node": ">= 0.8" } }, + "node_modules/express/node_modules/encodeurl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", + "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", + "engines": { + "node": ">= 0.8" + } + }, "node_modules/express/node_modules/safe-buffer": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", @@ -11689,26 +12285,11 @@ "node_modules/fresh": { "version": "0.5.2", "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", - "integrity": "sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac=", + "integrity": "sha512-zJ2mQYM18rEFOudeV4GShTGIQ7RbzA7ozbU9I/XBpm7kqgMywgmylMwXHxZJmkVoYkna9d2pVXVXPdYTP9ej8Q==", "engines": { "node": ">= 0.6" } }, - "node_modules/fs-extra": { - "version": "9.0.1", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.0.1.tgz", - "integrity": "sha512-h2iAoN838FqAFJY2/qVpzFXy+EBxfVE220PalAqQLDVsFOHLJrZvut5puAbCdNv6WJk+B8ihI+k0c7JK5erwqQ==", - "dev": true, - "dependencies": { - "at-least-node": "^1.0.0", - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^1.0.0" - }, - "engines": { - "node": ">=10" - } - }, "node_modules/fs-monkey": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/fs-monkey/-/fs-monkey-1.0.3.tgz", @@ -11742,9 +12323,12 @@ } }, "node_modules/function-bind": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", - "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", + "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } }, "node_modules/function.prototype.name": { "version": "1.1.5", @@ -11779,12 +12363,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/fuzzaldrin": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fuzzaldrin/-/fuzzaldrin-2.1.0.tgz", - "integrity": "sha1-kCBMPi/appQbso0WZF1BgGOpDps=", - "dev": true - }, "node_modules/gensync": { "version": "1.0.0-beta.2", "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz", @@ -11804,13 +12382,21 @@ } }, "node_modules/get-intrinsic": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.1.1.tgz", - "integrity": "sha512-kWZrnVM42QCiEA2Ig1bG8zjoIMOgxWwYCEeNdwY6Tv/cOSeGpcoX4pXHfKUxNKVoArnrEr2e9srnAxxGIraS9Q==", + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.4.tgz", + "integrity": "sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==", "dependencies": { - "function-bind": "^1.1.1", - "has": "^1.0.3", - "has-symbols": "^1.0.1" + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "hasown": "^2.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, "node_modules/get-nonce": { @@ -11919,7 +12505,6 @@ "version": "11.12.0", "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", - "devOptional": true, "engines": { "node": ">=4" } @@ -11949,10 +12534,21 @@ "node": ">=0.10.0" } }, + "node_modules/gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "dependencies": { + "get-intrinsic": "^1.1.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/graceful-fs": { - "version": "4.2.9", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.9.tgz", - "integrity": "sha512-NtNxqUcXgpW2iMrfqSfR73Glt39K+BLwWsPs94yR63v45T0Wbej7eRmL5cWfwEgqXnmjQp3zaJTshdRW/qC2ZQ==", + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", "dev": true }, "node_modules/graphql": { @@ -12048,12 +12644,22 @@ } }, "node_modules/has-property-descriptors": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz", - "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==", - "dev": true, + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz", + "integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==", "dependencies": { - "get-intrinsic": "^1.1.1" + "es-define-property": "^1.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-proto": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.3.tgz", + "integrity": "sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==", + "engines": { + "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" @@ -12148,6 +12754,17 @@ "node": ">=0.10.0" } }, + "node_modules/hasown": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", + "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", + "dependencies": { + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, "node_modules/he": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", @@ -12537,15 +13154,18 @@ "dev": true }, "node_modules/import-fresh": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.2.1.tgz", - "integrity": "sha512-6e1q1cnWP2RXD9/keSkxHScg508CdXqXWgWBaETNhyuBFz+kUZlKboh+ISK+bU++DmbHimVBrOz/zzPe0sZ3sQ==", + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", + "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==", "dependencies": { "parent-module": "^1.0.0", "resolve-from": "^4.0.0" }, "engines": { "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/import-local": { @@ -12815,22 +13435,6 @@ "node": ">=0.10.0" } }, - "node_modules/is-alphabetical": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-alphabetical/-/is-alphabetical-1.0.4.tgz", - "integrity": "sha512-DwzsA04LQ10FHTZuL0/grVDk4rFoVH1pjAToYwBrHSxcrBIGQuXrQMtD5U1b0U2XVgKZCTLLP8u2Qxqhy3l2Vg==", - "dev": true - }, - "node_modules/is-alphanumerical": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-alphanumerical/-/is-alphanumerical-1.0.4.tgz", - "integrity": "sha512-UzoZUr+XfVz3t3v4KyGEniVL9BDRoQtY7tOyrRybkVNjDFWyo1yhXNGrrBTQxp3ib9BLAWs7k2YKBQsFRkZG9A==", - "dev": true, - "dependencies": { - "is-alphabetical": "^1.0.0", - "is-decimal": "^1.0.0" - } - }, "node_modules/is-bigint": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", @@ -12945,12 +13549,6 @@ "node": ">= 0.4" } }, - "node_modules/is-decimal": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-decimal/-/is-decimal-1.0.4.tgz", - "integrity": "sha512-RGdriMmQQvZ2aqaQq3awNA6dCGtKpiDFcOzrTWrDAT2MiWrKQVPmxLGHl7Y2nNu6led0kEyoX0enY0qXYsv9zw==", - "dev": true - }, "node_modules/is-descriptor": { "version": "0.1.6", "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", @@ -15045,9 +15643,9 @@ } }, "node_modules/jest-worker": { - "version": "27.4.2", - "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-27.4.2.tgz", - "integrity": "sha512-0QMy/zPovLfUPyHuOuuU4E+kGACXXE84nRnq6lBVI9GJg5DCBiA97SATi+ZP8CpiJwEQy1oCPjRBf8AnLjN+Ag==", + "version": "27.5.1", + "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-27.5.1.tgz", + "integrity": "sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg==", "dev": true, "dependencies": { "@types/node": "*", @@ -15082,6 +15680,20 @@ "url": "https://github.com/chalk/supports-color?sponsor=1" } }, + "node_modules/jiti": { + "version": "1.21.6", + "resolved": "https://registry.npmjs.org/jiti/-/jiti-1.21.6.tgz", + "integrity": "sha512-2yTgeWTWzMWkHu6Jp9NKgePDaYHbntiwvYuuJLbbN9vl7DC9DvXKOB2BC3ZZ92D3cvV/aflH0osDfwpHepQ53w==", + "dev": true, + "bin": { + "jiti": "bin/jiti.js" + } + }, + "node_modules/js-sha256": { + "version": "0.10.1", + "resolved": "https://registry.npmjs.org/js-sha256/-/js-sha256-0.10.1.tgz", + "integrity": "sha512-5obBtsz9301ULlsgggLg542s/jqtddfOpV5KJc4hajc9JV8GeY2gZHSVpYBn4nWqAUTJ9v+xwtbJ1mIBgIH5Vw==" + }, "node_modules/js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", @@ -15150,7 +15762,6 @@ "version": "2.5.2", "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", - "devOptional": true, "bin": { "jsesc": "bin/jsesc" }, @@ -15170,16 +15781,10 @@ "node": ">= 12" } }, - "node_modules/json-parse-better-errors": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz", - "integrity": "sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==" - }, "node_modules/json-parse-even-better-errors": { "version": "2.3.1", "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", - "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", - "dev": true + "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==" }, "node_modules/json-schema-traverse": { "version": "0.4.1", @@ -15205,16 +15810,6 @@ "node": ">=6" } }, - "node_modules/jsonfile": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.0.1.tgz", - "integrity": "sha512-jR2b5v7d2vIOust+w3wtFKZIfpC2pnRmFAhAC/BuweZFQR8qZzxH1OyrQ10HmdVYiXWkYUqPVsz91cG7EL2FBg==", - "dev": true, - "dependencies": { - "graceful-fs": "^4.1.6", - "universalify": "^1.0.0" - } - }, "node_modules/jsonwebtoken": { "version": "9.0.0", "resolved": "https://registry.npmjs.org/jsonwebtoken/-/jsonwebtoken-9.0.0.tgz", @@ -15589,12 +16184,6 @@ "semver": "bin/semver.js" } }, - "node_modules/make-error": { - "version": "1.3.6", - "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", - "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", - "dev": true - }, "node_modules/make-plural": { "version": "7.1.0", "resolved": "https://registry.npmjs.org/make-plural/-/make-plural-7.1.0.tgz", @@ -15661,9 +16250,12 @@ "integrity": "sha512-rkpe71W0N0c0Xz6QD0eJETuWAJGnJ9afsl1srmwPrI+yBCkge5EycXXbYRyvL29zZVUWQCY7InPRCv3GDXuZNw==" }, "node_modules/merge-descriptors": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", - "integrity": "sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E=" + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", + "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==", + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } }, "node_modules/merge-stream": { "version": "2.0.0", @@ -15680,11 +16272,6 @@ "node": ">= 8" } }, - "node_modules/messageformat-parser": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/messageformat-parser/-/messageformat-parser-4.1.3.tgz", - "integrity": "sha512-2fU3XDCanRqeOCkn7R5zW5VQHWf+T3hH65SzuqRvjatBK7r4uyFa5mEX+k6F9Bd04LVM5G4/BHBTUJsOdW7uyg==" - }, "node_modules/methods": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", @@ -15812,17 +16399,10 @@ "node": ">=0.10.0" } }, - "node_modules/mkdirp": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "dev": true, - "bin": { - "mkdirp": "bin/cmd.js" - }, - "engines": { - "node": ">=10" - } + "node_modules/moo": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/moo/-/moo-0.5.2.tgz", + "integrity": "sha512-iSAJLHYKnX41mKcJKjqvnAN9sf0LMDTXDEvFv+ffuRR9a1MIuXLjMNL6EsnDHSkKLTWNqQQ5uo61P4EbU4NU+Q==" }, "node_modules/mq-polyfill": { "version": "1.1.8", @@ -15979,15 +16559,6 @@ "node": ">= 6.13.0" } }, - "node_modules/node-gettext": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/node-gettext/-/node-gettext-3.0.0.tgz", - "integrity": "sha512-/VRYibXmVoN6tnSAY2JWhNRhWYJ8Cd844jrZU/DwLVoI4vBI6ceYbd8i42sYZ9uOgDH3S7vslIKOWV/ZrT2YBA==", - "dev": true, - "dependencies": { - "lodash.get": "^4.4.2" - } - }, "node_modules/node-int64": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz", @@ -16035,9 +16606,9 @@ } }, "node_modules/node-releases": { - "version": "2.0.14", - "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.14.tgz", - "integrity": "sha512-y10wOWt8yZpqXmOgRo77WaHEmhYQYGNA6y421PKsKYWEK8aW+cqAphborZDhqfyKrbZEN92CN1X2KbafY2s7Yw==", + "version": "2.0.18", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.18.tgz", + "integrity": "sha512-d9VeXT4SJ7ZeOqGX6R5EM022wpL+eWPooLI+5UpWn2jCT1aosUQEhQP214x33Wkwx3JQMvIm+tIoVOdodFS40g==", "devOptional": true }, "node_modules/nodemon": { @@ -16226,9 +16797,12 @@ } }, "node_modules/object-inspect": { - "version": "1.12.2", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.2.tgz", - "integrity": "sha512-z+cPxW0QGUp0mcqcsgQyLVRDoXFQbXOwBaqyF7VIgI4TWNQsDHrBpUQslRmIfAoYWdYzs6UlKJtB2XJpTaNSpQ==", + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.2.tgz", + "integrity": "sha512-IRZSRuzJiynemAXPYtPe5BoI/RESNYR7TYm50MC5Mqbd3Jmw5y790sErYw3V6SryFJD64b74qQQs9wn5Bg/k3g==", + "engines": { + "node": ">= 0.4" + }, "funding": { "url": "https://github.com/sponsors/ljharb" } @@ -16602,12 +17176,6 @@ "node": ">=6" } }, - "node_modules/papaparse": { - "version": "5.3.0", - "resolved": "https://registry.npmjs.org/papaparse/-/papaparse-5.3.0.tgz", - "integrity": "sha512-Lb7jN/4bTpiuGPrYy4tkKoUS8sTki8zacB5ke1p5zolhcSE4TlWgrlsxjrDTbG/dFVh07ck7X36hUf/b5V68pg==", - "dev": true - }, "node_modules/param-case": { "version": "3.0.4", "resolved": "https://registry.npmjs.org/param-case/-/param-case-3.0.4.tgz", @@ -16636,17 +17204,20 @@ } }, "node_modules/parse-json": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.0.1.tgz", - "integrity": "sha512-ztoZ4/DYeXQq4E21v169sC8qWINGpcosGv9XhTDvg9/hWvx/zrFkc9BiWxR58OJLHGk28j5BL0SDLeV2WmFZlQ==", + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz", + "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==", "dependencies": { "@babel/code-frame": "^7.0.0", "error-ex": "^1.3.1", - "json-parse-better-errors": "^1.0.1", + "json-parse-even-better-errors": "^2.3.0", "lines-and-columns": "^1.1.6" }, "engines": { "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, "node_modules/parse5": { @@ -16727,9 +17298,9 @@ "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==" }, "node_modules/path-to-regexp": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", - "integrity": "sha1-32BBeABfUi8V60SQ5yR6G/qmf4w=" + "version": "0.1.10", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.10.tgz", + "integrity": "sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w==" }, "node_modules/path-type": { "version": "4.0.0", @@ -16739,11 +17310,16 @@ "node": ">=8" } }, + "node_modules/pathe": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/pathe/-/pathe-1.1.2.tgz", + "integrity": "sha512-whLdWMYL2TwI08hn8/ZqAbrVemu0LNaNNJZX73O6qaIdCTfXutsLhMkjdENX0qhsQ9uIimo4/aQOmXkoon2nDQ==", + "dev": true + }, "node_modules/picocolors": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", - "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", - "devOptional": true + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.1.tgz", + "integrity": "sha512-anP1Z8qwhkbmu7MFP5iTt+wQKXgwzf7zTyGlcdzabySa9vd0Xt392U0rVmz9poOaBj0uHJKyyo9/upk0HrEQew==" }, "node_modules/picomatch": { "version": "2.3.1", @@ -16811,16 +17387,10 @@ "node": ">=8" } }, - "node_modules/plurals-cldr": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/plurals-cldr/-/plurals-cldr-1.0.4.tgz", - "integrity": "sha512-4nLXqtel7fsCgzi8dvRZvUjfL8SXpP982sKg7b2TgpnR8rDnes06iuQ83trQ/+XdtyMIQkBBbKzX6x97eLfsJQ==", - "dev": true - }, "node_modules/pofile": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/pofile/-/pofile-1.1.0.tgz", - "integrity": "sha512-6XYcNkXWGiJ2CVXogTP7uJ6ZXQCldYLZc16wgRp8tqRaBTTyIfF+TUT3EQJPXTLAT7OTPpTAoaFdoXKfaTRU1w==", + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/pofile/-/pofile-1.1.4.tgz", + "integrity": "sha512-r6Q21sKsY1AjTVVjOuU02VYKVNQGJNQHjTIvs4dEbeuuYfxgYk/DGD2mqqq4RDaVkwdSq0VEtmQUOPe/wH8X3g==", "dev": true }, "node_modules/popmotion": { @@ -16998,12 +17568,18 @@ } }, "node_modules/pseudolocale": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/pseudolocale/-/pseudolocale-1.2.0.tgz", - "integrity": "sha512-k0OQFvIlvpRdzR0dPVrrbWX7eE9EaZ6gpZtTlFSDi1Gf9tMy9wiANCNu7JZ0drcKgUri/39a2mBbH0goiQmrmQ==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/pseudolocale/-/pseudolocale-2.1.0.tgz", + "integrity": "sha512-af5fsrRvVwD+MBasBJvuDChT0KDqT0nEwD9NTgbtHJ16FKomWac9ua0z6YVNB4G9x9IOaiGWym62aby6n4tFMA==", "dev": true, "dependencies": { - "commander": "*" + "commander": "^10.0.0" + }, + "bin": { + "pseudolocale": "dist/cli.mjs" + }, + "engines": { + "node": ">=16.0.0" } }, "node_modules/psl": { @@ -17589,9 +18165,9 @@ } }, "node_modules/regenerator-runtime": { - "version": "0.13.7", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.7.tgz", - "integrity": "sha512-a54FxoJDIr27pgf7IgeQGxmqUNYrcV338lf/6gH456HZ/PhX+5BcwHXG9ajESmwe6WRO0tAzRUrRmNONWgkrew==" + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==" }, "node_modules/regenerator-transform": { "version": "0.15.0", @@ -18183,9 +18759,9 @@ } }, "node_modules/send": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", - "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "version": "0.19.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", + "integrity": "sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==", "dependencies": { "debug": "2.6.9", "depd": "2.0.0", @@ -18227,9 +18803,9 @@ } }, "node_modules/serialize-javascript": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.0.tgz", - "integrity": "sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag==", + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz", + "integrity": "sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==", "dev": true, "dependencies": { "randombytes": "^2.1.0" @@ -18275,9 +18851,9 @@ "dev": true }, "node_modules/serve-static": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.15.0.tgz", - "integrity": "sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==", + "version": "1.16.0", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.16.0.tgz", + "integrity": "sha512-pDLK8zwl2eKaYrs8mrPZBJua4hMplRWJ1tIFksVC3FtBEBnl8dxgeHtsaMS8DhS9i4fLObaon6ABoc4/hQGdPA==", "dependencies": { "encodeurl": "~1.0.2", "escape-html": "~1.0.3", @@ -18288,12 +18864,72 @@ "node": ">= 0.8.0" } }, + "node_modules/serve-static/node_modules/depd": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", + "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/serve-static/node_modules/ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==" + }, + "node_modules/serve-static/node_modules/send": { + "version": "0.18.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", + "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "dependencies": { + "debug": "2.6.9", + "depd": "2.0.0", + "destroy": "1.2.0", + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "etag": "~1.8.1", + "fresh": "0.5.2", + "http-errors": "2.0.0", + "mime": "1.6.0", + "ms": "2.1.3", + "on-finished": "2.4.1", + "range-parser": "~1.2.1", + "statuses": "2.0.1" + }, + "engines": { + "node": ">= 0.8.0" + } + }, + "node_modules/serve-static/node_modules/statuses": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", + "integrity": "sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ==", + "engines": { + "node": ">= 0.8" + } + }, "node_modules/set-blocking": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", "dev": true }, + "node_modules/set-function-length": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", + "integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==", + "dependencies": { + "define-data-property": "^1.1.4", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + } + }, "node_modules/set-value": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/set-value/-/set-value-2.0.1.tgz", @@ -18386,13 +19022,17 @@ "optional": true }, "node_modules/side-channel": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", - "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.6.tgz", + "integrity": "sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==", "dependencies": { - "call-bind": "^1.0.0", - "get-intrinsic": "^1.0.2", - "object-inspect": "^1.9.0" + "call-bind": "^1.0.7", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.4", + "object-inspect": "^1.13.1" + }, + "engines": { + "node": ">= 0.4" }, "funding": { "url": "https://github.com/sponsors/ljharb" @@ -19354,16 +19994,16 @@ } }, "node_modules/terser-webpack-plugin": { - "version": "5.2.5", - "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.2.5.tgz", - "integrity": "sha512-3luOVHku5l0QBeYS8r4CdHYWEGMmIj3H1U64jgkdZzECcSOJAyJ9TjuqcQZvw1Y+4AOBN9SeYJPJmFn2cM4/2g==", + "version": "5.3.10", + "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.10.tgz", + "integrity": "sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==", "dev": true, "dependencies": { - "jest-worker": "^27.0.6", + "@jridgewell/trace-mapping": "^0.3.20", + "jest-worker": "^27.4.5", "schema-utils": "^3.1.1", - "serialize-javascript": "^6.0.0", - "source-map": "^0.6.1", - "terser": "^5.7.2" + "serialize-javascript": "^6.0.1", + "terser": "^5.26.0" }, "engines": { "node": ">= 10.13.0" @@ -19388,9 +20028,9 @@ } }, "node_modules/terser-webpack-plugin/node_modules/schema-utils": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.1.1.tgz", - "integrity": "sha512-Y5PQxS4ITlC+EahLuXaY86TXfR7Dc5lw294alXOq86JAHCihAIZfqv8nNCWvaEJvaC51uN9hbLGeV0cFBdH+Fw==", + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.3.0.tgz", + "integrity": "sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==", "dev": true, "dependencies": { "@types/json-schema": "^7.0.8", @@ -19405,15 +20045,6 @@ "url": "https://opencollective.com/webpack" } }, - "node_modules/terser-webpack-plugin/node_modules/source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/terser/node_modules/commander": { "version": "2.20.3", "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", @@ -19627,32 +20258,6 @@ "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.0.tgz", "integrity": "sha512-d6xOpEDfsi2CZVlPQzGeux8XMwLT9hssAsaPYExaQMuYskwb+x1x7J371tWlbBdWHroy99KnVB6qIkUbs5X3UQ==" }, - "node_modules/ts-node": { - "version": "9.1.1", - "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-9.1.1.tgz", - "integrity": "sha512-hPlt7ZACERQGf03M253ytLY3dHbGNGrAq9qIHWUY9XHYl1z7wYngSr3OQ5xmui8o2AaxsONxIzjafLUiWBo1Fg==", - "dev": true, - "dependencies": { - "arg": "^4.1.0", - "create-require": "^1.1.0", - "diff": "^4.0.1", - "make-error": "^1.1.1", - "source-map-support": "^0.5.17", - "yn": "3.1.1" - }, - "bin": { - "ts-node": "dist/bin.js", - "ts-node-script": "dist/bin-script.js", - "ts-node-transpile-only": "dist/bin-transpile.js", - "ts-script": "dist/bin-script-deprecated.js" - }, - "engines": { - "node": ">=10.0.0" - }, - "peerDependencies": { - "typescript": ">=2.7" - } - }, "node_modules/tsconfig-paths": { "version": "3.14.1", "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.14.1.tgz", @@ -19843,15 +20448,6 @@ "node": ">=0.10.0" } }, - "node_modules/universalify": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/universalify/-/universalify-1.0.0.tgz", - "integrity": "sha512-rb6X1W158d7pRQBg5gkR8uPaSfiids68LTJQYOtEUhoJUWBdaQHsuT/EUduxXYxcrt4r5PJ4fuHW1MHT6p0qug==", - "dev": true, - "engines": { - "node": ">= 10.0.0" - } - }, "node_modules/unpipe": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", @@ -19860,6 +20456,11 @@ "node": ">= 0.8" } }, + "node_modules/unraw": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/unraw/-/unraw-3.0.0.tgz", + "integrity": "sha512-08/DA66UF65OlpUDIQtbJyrqTR0jTAlJ+jsnkQ4jxR7+K5g5YG1APZKQSMCE1vqqmD+2pv6+IdEjmopFatacvg==" + }, "node_modules/unset-value": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/unset-value/-/unset-value-1.0.0.tgz", @@ -19915,9 +20516,9 @@ "dev": true }, "node_modules/update-browserslist-db": { - "version": "1.0.13", - "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.13.tgz", - "integrity": "sha512-xebP81SNcPuNpPP3uzeW1NYXxI3rxyJzF3pD6sH4jE7o/IX+WtSpwnVU+qIsDPyk0d3hmFQ7mjqc6AtV604hbg==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.1.0.tgz", + "integrity": "sha512-EdRAaAyk2cUE1wOf2DkEhzxqOQvFOoRJFNS6NeyJ01Gp2beMRpBAINjM2iDXE3KCuKhwnvHIQCJm6ThL2Z+HzQ==", "devOptional": true, "funding": [ { @@ -19934,8 +20535,8 @@ } ], "dependencies": { - "escalade": "^3.1.1", - "picocolors": "^1.0.0" + "escalade": "^3.1.2", + "picocolors": "^1.0.1" }, "bin": { "update-browserslist-db": "cli.js" @@ -20150,9 +20751,9 @@ } }, "node_modules/watchpack": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.0.tgz", - "integrity": "sha512-Lcvm7MGST/4fup+ifyKi2hjyIAwcdI4HRgtvTpIUxBRhB+RFtUh8XtDOxUfctVCnhVi+QQj49i91OyvzkJl6cg==", + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.2.tgz", + "integrity": "sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==", "dev": true, "dependencies": { "glob-to-regexp": "^0.4.1", @@ -20190,34 +20791,33 @@ } }, "node_modules/webpack": { - "version": "5.76.2", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.76.2.tgz", - "integrity": "sha512-Th05ggRm23rVzEOlX8y67NkYCHa9nTNcwHPBhdg+lKG+mtiW7XgggjAeeLnADAe7mLjJ6LUNfgHAuRRh+Z6J7w==", + "version": "5.94.0", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.94.0.tgz", + "integrity": "sha512-KcsGn50VT+06JH/iunZJedYGUJS5FGjow8wb9c0v5n1Om8O1g4L6LjtfxwlXIATopoQu+vOXXa7gYisWxCoPyg==", "dev": true, "dependencies": { - "@types/eslint-scope": "^3.7.3", - "@types/estree": "^0.0.51", - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/wasm-edit": "1.11.1", - "@webassemblyjs/wasm-parser": "1.11.1", + "@types/estree": "^1.0.5", + "@webassemblyjs/ast": "^1.12.1", + "@webassemblyjs/wasm-edit": "^1.12.1", + "@webassemblyjs/wasm-parser": "^1.12.1", "acorn": "^8.7.1", - "acorn-import-assertions": "^1.7.6", - "browserslist": "^4.14.5", + "acorn-import-attributes": "^1.9.5", + "browserslist": "^4.21.10", "chrome-trace-event": "^1.0.2", - "enhanced-resolve": "^5.10.0", - "es-module-lexer": "^0.9.0", + "enhanced-resolve": "^5.17.1", + "es-module-lexer": "^1.2.1", "eslint-scope": "5.1.1", "events": "^3.2.0", "glob-to-regexp": "^0.4.1", - "graceful-fs": "^4.2.9", + "graceful-fs": "^4.2.11", "json-parse-even-better-errors": "^2.3.1", "loader-runner": "^4.2.0", "mime-types": "^2.1.27", "neo-async": "^2.6.2", - "schema-utils": "^3.1.0", + "schema-utils": "^3.2.0", "tapable": "^2.1.1", - "terser-webpack-plugin": "^5.1.3", - "watchpack": "^2.4.0", + "terser-webpack-plugin": "^5.3.10", + "watchpack": "^2.4.1", "webpack-sources": "^3.2.3" }, "bin": { @@ -20597,9 +21197,9 @@ } }, "node_modules/webpack/node_modules/schema-utils": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.1.1.tgz", - "integrity": "sha512-Y5PQxS4ITlC+EahLuXaY86TXfR7Dc5lw294alXOq86JAHCihAIZfqv8nNCWvaEJvaC51uN9hbLGeV0cFBdH+Fw==", + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.3.0.tgz", + "integrity": "sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==", "dev": true, "dependencies": { "@types/json-schema": "^7.0.8", @@ -20945,15 +21545,6 @@ "node": ">=8" } }, - "node_modules/yn": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", - "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", - "dev": true, - "engines": { - "node": ">=6" - } - }, "node_modules/yup": { "version": "0.32.11", "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.11.tgz", @@ -21190,43 +21781,49 @@ } }, "@babel/code-frame": { - "version": "7.22.13", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.22.13.tgz", - "integrity": "sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w==", + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.24.7.tgz", + "integrity": "sha512-BcYH1CVJBO9tvyIZ2jVeXgSIMvGZ2FDRvDdOIVQyuklNKSsx+eppDEBq/g47Ayw+RqNFE+URvOShmf+f/qwAlA==", "requires": { - "@babel/highlight": "^7.22.13", - "chalk": "^2.4.2" + "@babel/highlight": "^7.24.7", + "picocolors": "^1.0.0" } }, "@babel/compat-data": { - "version": "7.18.8", - "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.18.8.tgz", - "integrity": "sha512-HSmX4WZPPK3FUxYp7g2T6EyO8j96HlZJlxmKPSh6KAcqwyDrfx7hKjXpAW/0FhFfTJsR0Yt4lAjLI2coMptIHQ==", + "version": "7.25.4", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.25.4.tgz", + "integrity": "sha512-+LGRog6RAsCJrrrg/IO6LGmpphNe5DiK30dGjCoxxeGv49B10/3XYGxPsAwrDlMFcFEvdAUavDT8r9k/hSyQqQ==", "devOptional": true }, "@babel/core": { - "version": "7.18.10", - "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.18.10.tgz", - "integrity": "sha512-JQM6k6ENcBFKVtWvLavlvi/mPcpYZ3+R+2EySDEMSMbp7Mn4FexlbbJVrx2R7Ijhr01T8gyqrOaABWIOgxeUyw==", + "version": "7.25.2", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.25.2.tgz", + "integrity": "sha512-BBt3opiCOxUr9euZ5/ro/Xv8/V7yJ5bjYMqG/C1YAo8MIKAnumZalCN+msbci3Pigy4lIQfPUpfMM27HMGaYEA==", "devOptional": true, "requires": { - "@ampproject/remapping": "^2.1.0", - "@babel/code-frame": "^7.18.6", - "@babel/generator": "^7.18.10", - "@babel/helper-compilation-targets": "^7.18.9", - "@babel/helper-module-transforms": "^7.18.9", - "@babel/helpers": "^7.18.9", - "@babel/parser": "^7.18.10", - "@babel/template": "^7.18.10", - "@babel/traverse": "^7.18.10", - "@babel/types": "^7.18.10", - "convert-source-map": "^1.7.0", + "@ampproject/remapping": "^2.2.0", + "@babel/code-frame": "^7.24.7", + "@babel/generator": "^7.25.0", + "@babel/helper-compilation-targets": "^7.25.2", + "@babel/helper-module-transforms": "^7.25.2", + "@babel/helpers": "^7.25.0", + "@babel/parser": "^7.25.0", + "@babel/template": "^7.25.0", + "@babel/traverse": "^7.25.2", + "@babel/types": "^7.25.2", + "convert-source-map": "^2.0.0", "debug": "^4.1.0", "gensync": "^1.0.0-beta.2", - "json5": "^2.2.1", - "semver": "^6.3.0" + "json5": "^2.2.3", + "semver": "^6.3.1" }, "dependencies": { + "convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", + "devOptional": true + }, "debug": { "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", @@ -21251,26 +21848,24 @@ } }, "@babel/generator": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.23.0.tgz", - "integrity": "sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g==", - "devOptional": true, + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.25.6.tgz", + "integrity": "sha512-VPC82gr1seXOpkjAAKoLhP50vx4vGNlF4msF64dSFq1P8RfB+QAuJWGHPXXPc8QyfVWwwB/TNNU4+ayZmHNbZw==", "requires": { - "@babel/types": "^7.23.0", - "@jridgewell/gen-mapping": "^0.3.2", - "@jridgewell/trace-mapping": "^0.3.17", + "@babel/types": "^7.25.6", + "@jridgewell/gen-mapping": "^0.3.5", + "@jridgewell/trace-mapping": "^0.3.25", "jsesc": "^2.5.1" }, "dependencies": { "@jridgewell/gen-mapping": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.2.tgz", - "integrity": "sha512-mh65xKQAzI6iBcFzwv28KVWSmCkdRBWoOh+bYQGW3+6OZvbbN3TqMGo5hqYxQniRcH9F2VZIoJCm4pa3BPDK/A==", - "devOptional": true, + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", + "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==", "requires": { - "@jridgewell/set-array": "^1.0.1", + "@jridgewell/set-array": "^1.2.1", "@jridgewell/sourcemap-codec": "^1.4.10", - "@jridgewell/trace-mapping": "^0.3.9" + "@jridgewell/trace-mapping": "^0.3.24" } } } @@ -21295,22 +21890,38 @@ } }, "@babel/helper-compilation-targets": { - "version": "7.18.9", - "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.18.9.tgz", - "integrity": "sha512-tzLCyVmqUiFlcFoAPLA/gL9TeYrF61VLNtb+hvkuVaB5SUjW7jcfrglBIX1vUIoT7CLP3bBlIMeyEsIl2eFQNg==", + "version": "7.25.2", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.25.2.tgz", + "integrity": "sha512-U2U5LsSaZ7TAt3cfaymQ8WHh0pxvdHoEk6HVpaexxixjyEquMh0L0YNJNM6CTGKMXV1iksi0iZkGw4AcFkPaaw==", "devOptional": true, "requires": { - "@babel/compat-data": "^7.18.8", - "@babel/helper-validator-option": "^7.18.6", - "browserslist": "^4.20.2", - "semver": "^6.3.0" + "@babel/compat-data": "^7.25.2", + "@babel/helper-validator-option": "^7.24.8", + "browserslist": "^4.23.1", + "lru-cache": "^5.1.1", + "semver": "^6.3.1" }, "dependencies": { + "lru-cache": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", + "integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==", + "devOptional": true, + "requires": { + "yallist": "^3.0.2" + } + }, "semver": { "version": "6.3.1", "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", "devOptional": true + }, + "yallist": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", + "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==", + "devOptional": true } } }, @@ -21380,7 +21991,7 @@ "version": "7.22.20", "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.22.20.tgz", "integrity": "sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA==", - "devOptional": true + "dev": true }, "@babel/helper-explode-assignable-expression": { "version": "7.18.6", @@ -21395,7 +22006,7 @@ "version": "7.23.0", "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.23.0.tgz", "integrity": "sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==", - "devOptional": true, + "dev": true, "requires": { "@babel/template": "^7.22.15", "@babel/types": "^7.23.0" @@ -21405,7 +22016,7 @@ "version": "7.22.5", "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.22.5.tgz", "integrity": "sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==", - "devOptional": true, + "dev": true, "requires": { "@babel/types": "^7.22.5" } @@ -21420,27 +22031,24 @@ } }, "@babel/helper-module-imports": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.18.6.tgz", - "integrity": "sha512-0NFvs3VkuSYbFi1x2Vd6tKrywq+z/cLeYC/RJNFrIX/30Bf5aiGYbtvGXolEktzJH8o5E5KJ3tT+nkxuuZFVlA==", + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.24.7.tgz", + "integrity": "sha512-8AyH3C+74cgCVVXow/myrynrAGv+nTVg5vKu2nZph9x7RcRwzmh0VFallJuFTZ9mx6u4eSdXZfcOzSqTUm0HCA==", "requires": { - "@babel/types": "^7.18.6" + "@babel/traverse": "^7.24.7", + "@babel/types": "^7.24.7" } }, "@babel/helper-module-transforms": { - "version": "7.18.9", - "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.18.9.tgz", - "integrity": "sha512-KYNqY0ICwfv19b31XzvmI/mfcylOzbLtowkw+mfvGPAQ3kfCnMLYbED3YecL5tPd8nAYFQFAd6JHp2LxZk/J1g==", + "version": "7.25.2", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.25.2.tgz", + "integrity": "sha512-BjyRAbix6j/wv83ftcVJmBt72QtHI56C7JXZoG2xATiLpmoC7dpd8WnkikExHDVPpi/3qCmO6WY1EaXOluiecQ==", "devOptional": true, "requires": { - "@babel/helper-environment-visitor": "^7.18.9", - "@babel/helper-module-imports": "^7.18.6", - "@babel/helper-simple-access": "^7.18.6", - "@babel/helper-split-export-declaration": "^7.18.6", - "@babel/helper-validator-identifier": "^7.18.6", - "@babel/template": "^7.18.6", - "@babel/traverse": "^7.18.9", - "@babel/types": "^7.18.9" + "@babel/helper-module-imports": "^7.24.7", + "@babel/helper-simple-access": "^7.24.7", + "@babel/helper-validator-identifier": "^7.24.7", + "@babel/traverse": "^7.25.2" } }, "@babel/helper-optimise-call-expression": { @@ -21484,12 +22092,13 @@ } }, "@babel/helper-simple-access": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.18.6.tgz", - "integrity": "sha512-iNpIgTgyAvDQpDj76POqg+YEt8fPxx3yaNBg3S30dxNKm2SWfYhD0TGrK/Eu9wHpUW63VQU894TsTg+GLbUa1g==", + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.24.7.tgz", + "integrity": "sha512-zBAIvbCMh5Ts+b86r/CjU+4XGYIs+R1j951gxI3KmmxBMhCg4oQMsv6ZXQ64XOm/cvzfU1FmoCyt6+owc5QMYg==", "devOptional": true, "requires": { - "@babel/types": "^7.18.6" + "@babel/traverse": "^7.24.7", + "@babel/types": "^7.24.7" } }, "@babel/helper-skip-transparent-expression-wrappers": { @@ -21505,25 +22114,25 @@ "version": "7.22.6", "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.22.6.tgz", "integrity": "sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==", - "devOptional": true, + "dev": true, "requires": { "@babel/types": "^7.22.5" } }, "@babel/helper-string-parser": { - "version": "7.22.5", - "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.22.5.tgz", - "integrity": "sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw==" + "version": "7.24.8", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.24.8.tgz", + "integrity": "sha512-pO9KhhRcuUyGnJWwyEgnRJTSIZHiT+vMD0kPeD+so0l7mxkMT19g3pjY9GTnHySck/hDzq+dtW/4VgnMkippsQ==" }, "@babel/helper-validator-identifier": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.20.tgz", - "integrity": "sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==" + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.24.7.tgz", + "integrity": "sha512-rR+PBcQ1SMQDDyF6X0wxtG8QyLCgUB0eRAGguqRLfkCA87l7yAP7ehq8SNj96OOGTO8OBV70KhuFYcIkHXOg0w==" }, "@babel/helper-validator-option": { - "version": "7.18.6", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.18.6.tgz", - "integrity": "sha512-XO7gESt5ouv/LRJdrVjkShckw6STTaB7l9BrpBaAHDeF5YZT+01PCwmR0SJHnkW6i8OwW/EVWRShfi4j2x+KQw==", + "version": "7.24.8", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.24.8.tgz", + "integrity": "sha512-xb8t9tD1MHLungh/AIoWYN+gVHaB9kwlu8gffXGSt3FFEIT7RjS+xWbc2vUD1UTZdIpKj/ab3rdqJ7ufngyi2Q==", "devOptional": true }, "@babel/helper-wrap-function": { @@ -21539,31 +22148,33 @@ } }, "@babel/helpers": { - "version": "7.18.9", - "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.18.9.tgz", - "integrity": "sha512-Jf5a+rbrLoR4eNdUmnFu8cN5eNJT6qdTdOg5IHIzq87WwyRw9PwguLFOWYgktN/60IP4fgDUawJvs7PjQIzELQ==", + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.25.6.tgz", + "integrity": "sha512-Xg0tn4HcfTijTwfDwYlvVCl43V6h4KyVVX2aEm4qdO/PC6L2YvzLHFdmxhoeSA3eslcE6+ZVXHgWwopXYLNq4Q==", "devOptional": true, "requires": { - "@babel/template": "^7.18.6", - "@babel/traverse": "^7.18.9", - "@babel/types": "^7.18.9" + "@babel/template": "^7.25.0", + "@babel/types": "^7.25.6" } }, "@babel/highlight": { - "version": "7.22.20", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.22.20.tgz", - "integrity": "sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg==", + "version": "7.24.7", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.24.7.tgz", + "integrity": "sha512-EStJpq4OuY8xYfhGVXngigBJRWxftKX9ksiGDnmlY3o7B/V7KIAc9X4oiK87uPJSc/vs5L869bem5fhZa8caZw==", "requires": { - "@babel/helper-validator-identifier": "^7.22.20", + "@babel/helper-validator-identifier": "^7.24.7", "chalk": "^2.4.2", - "js-tokens": "^4.0.0" + "js-tokens": "^4.0.0", + "picocolors": "^1.0.0" } }, "@babel/parser": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.23.0.tgz", - "integrity": "sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw==", - "devOptional": true + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.25.6.tgz", + "integrity": "sha512-trGdfBdbD0l1ZPmcJ83eNxB9rbEax4ALFTF7fN386TMYbeCQbyme5cOEXQhbGXKebwGaB/J52w1mrklMcbgy6Q==", + "requires": { + "@babel/types": "^7.25.6" + } }, "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": { "version": "7.18.6", @@ -22404,39 +23015,34 @@ } }, "@babel/runtime": { - "version": "7.18.9", - "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.18.9.tgz", - "integrity": "sha512-lkqXDcvlFT5rvEjiu6+QYO+1GXrEHRo2LOtS7E4GtX5ESIZOgepqsZBVIj6Pv+a6zqsya9VCgiK1KAK4BvJDAw==", + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.25.6.tgz", + "integrity": "sha512-VBj9MYyDb9tuLq7yzqjgzt6Q+IBQLrGZfdjOekyEirZPHxXWoTSGUTMrpsfi58Up73d13NfYLv8HT9vmznjzhQ==", "requires": { - "regenerator-runtime": "^0.13.4" + "regenerator-runtime": "^0.14.0" } }, "@babel/template": { - "version": "7.22.15", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.22.15.tgz", - "integrity": "sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w==", - "devOptional": true, + "version": "7.25.0", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.25.0.tgz", + "integrity": "sha512-aOOgh1/5XzKvg1jvVz7AVrx2piJ2XBi227DHmbY6y+bM9H2FlN+IfecYu4Xl0cNiiVejlsCri89LUsbj8vJD9Q==", "requires": { - "@babel/code-frame": "^7.22.13", - "@babel/parser": "^7.22.15", - "@babel/types": "^7.22.15" + "@babel/code-frame": "^7.24.7", + "@babel/parser": "^7.25.0", + "@babel/types": "^7.25.0" } }, "@babel/traverse": { - "version": "7.23.2", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.23.2.tgz", - "integrity": "sha512-azpe59SQ48qG6nu2CzcMLbxUudtN+dOM9kDbUqGq3HXUJRlo7i8fvPoxQUzYgLZ4cMVmuZgm8vvBpNeRhd6XSw==", - "devOptional": true, - "requires": { - "@babel/code-frame": "^7.22.13", - "@babel/generator": "^7.23.0", - "@babel/helper-environment-visitor": "^7.22.20", - "@babel/helper-function-name": "^7.23.0", - "@babel/helper-hoist-variables": "^7.22.5", - "@babel/helper-split-export-declaration": "^7.22.6", - "@babel/parser": "^7.23.0", - "@babel/types": "^7.23.0", - "debug": "^4.1.0", + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.25.6.tgz", + "integrity": "sha512-9Vrcx5ZW6UwK5tvqsj0nGpp/XzqthkT0dqIc9g1AdtygFToNtTF67XzYS//dm+SAK9cp3B9R4ZO/46p63SCjlQ==", + "requires": { + "@babel/code-frame": "^7.24.7", + "@babel/generator": "^7.25.6", + "@babel/parser": "^7.25.6", + "@babel/template": "^7.25.0", + "@babel/types": "^7.25.6", + "debug": "^4.3.1", "globals": "^11.1.0" }, "dependencies": { @@ -22444,7 +23050,6 @@ "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", - "devOptional": true, "requires": { "ms": "2.1.2" } @@ -22452,18 +23057,17 @@ "ms": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "devOptional": true + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" } } }, "@babel/types": { - "version": "7.23.0", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.23.0.tgz", - "integrity": "sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg==", + "version": "7.25.6", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.25.6.tgz", + "integrity": "sha512-/l42B1qxpG6RdfYf343Uw1vmDjeNhneUXtzhojE7pDgfpEypmRhI6j1kr17XCVv4Cgl9HdAiQY2x0GwKm7rWCw==", "requires": { - "@babel/helper-string-parser": "^7.22.5", - "@babel/helper-validator-identifier": "^7.22.20", + "@babel/helper-string-parser": "^7.24.8", + "@babel/helper-validator-identifier": "^7.24.7", "to-fast-properties": "^2.0.0" } }, @@ -23723,25 +24327,159 @@ "resolved": "https://registry.npmjs.org/@emotion/weak-memoize/-/weak-memoize-0.3.1.tgz", "integrity": "sha512-EsBwpc7hBUJWAsNPBmJy4hxWx12v6bshQsldrVmjxJoc3isbxhOrF2IcCpaXxfvq03NwkI7sbsOLXbYuqF/8Ww==" }, - "@endemolshinegroup/cosmiconfig-typescript-loader": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/@endemolshinegroup/cosmiconfig-typescript-loader/-/cosmiconfig-typescript-loader-3.0.2.tgz", - "integrity": "sha512-QRVtqJuS1mcT56oHpVegkKBlgtWjXw/gHNWO3eL9oyB5Sc7HBoc2OLG/nYpVfT/Jejvo3NUrD0Udk7XgoyDKkA==", + "@esbuild/android-arm": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.17.19.tgz", + "integrity": "sha512-rIKddzqhmav7MSmoFCmDIb6e2W57geRsM94gV2l38fzhXMwq7hZoClug9USI2pFRGL06f4IOPHHpFNOkWieR8A==", "dev": true, - "requires": { - "lodash.get": "^4", - "make-error": "^1", - "ts-node": "^9", - "tslib": "^2" - }, - "dependencies": { - "tslib": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.0.tgz", - "integrity": "sha512-d6xOpEDfsi2CZVlPQzGeux8XMwLT9hssAsaPYExaQMuYskwb+x1x7J371tWlbBdWHroy99KnVB6qIkUbs5X3UQ==", - "dev": true - } - } + "optional": true + }, + "@esbuild/android-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.17.19.tgz", + "integrity": "sha512-KBMWvEZooR7+kzY0BtbTQn0OAYY7CsiydT63pVEaPtVYF0hXbUaOyZog37DKxK7NF3XacBJOpYT4adIJh+avxA==", + "dev": true, + "optional": true + }, + "@esbuild/android-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.17.19.tgz", + "integrity": "sha512-uUTTc4xGNDT7YSArp/zbtmbhO0uEEK9/ETW29Wk1thYUJBz3IVnvgEiEwEa9IeLyvnpKrWK64Utw2bgUmDveww==", + "dev": true, + "optional": true + }, + "@esbuild/darwin-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.17.19.tgz", + "integrity": "sha512-80wEoCfF/hFKM6WE1FyBHc9SfUblloAWx6FJkFWTWiCoht9Mc0ARGEM47e67W9rI09YoUxJL68WHfDRYEAvOhg==", + "dev": true, + "optional": true + }, + "@esbuild/darwin-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.17.19.tgz", + "integrity": "sha512-IJM4JJsLhRYr9xdtLytPLSH9k/oxR3boaUIYiHkAawtwNOXKE8KoU8tMvryogdcT8AU+Bflmh81Xn6Q0vTZbQw==", + "dev": true, + "optional": true + }, + "@esbuild/freebsd-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.17.19.tgz", + "integrity": "sha512-pBwbc7DufluUeGdjSU5Si+P3SoMF5DQ/F/UmTSb8HXO80ZEAJmrykPyzo1IfNbAoaqw48YRpv8shwd1NoI0jcQ==", + "dev": true, + "optional": true + }, + "@esbuild/freebsd-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.17.19.tgz", + "integrity": "sha512-4lu+n8Wk0XlajEhbEffdy2xy53dpR06SlzvhGByyg36qJw6Kpfk7cp45DR/62aPH9mtJRmIyrXAS5UWBrJT6TQ==", + "dev": true, + "optional": true + }, + "@esbuild/linux-arm": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.17.19.tgz", + "integrity": "sha512-cdmT3KxjlOQ/gZ2cjfrQOtmhG4HJs6hhvm3mWSRDPtZ/lP5oe8FWceS10JaSJC13GBd4eH/haHnqf7hhGNLerA==", + "dev": true, + "optional": true + }, + "@esbuild/linux-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.17.19.tgz", + "integrity": "sha512-ct1Tg3WGwd3P+oZYqic+YZF4snNl2bsnMKRkb3ozHmnM0dGWuxcPTTntAF6bOP0Sp4x0PjSF+4uHQ1xvxfRKqg==", + "dev": true, + "optional": true + }, + "@esbuild/linux-ia32": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.17.19.tgz", + "integrity": "sha512-w4IRhSy1VbsNxHRQpeGCHEmibqdTUx61Vc38APcsRbuVgK0OPEnQ0YD39Brymn96mOx48Y2laBQGqgZ0j9w6SQ==", + "dev": true, + "optional": true + }, + "@esbuild/linux-loong64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.17.19.tgz", + "integrity": "sha512-2iAngUbBPMq439a+z//gE+9WBldoMp1s5GWsUSgqHLzLJ9WoZLZhpwWuym0u0u/4XmZ3gpHmzV84PonE+9IIdQ==", + "dev": true, + "optional": true + }, + "@esbuild/linux-mips64el": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.17.19.tgz", + "integrity": "sha512-LKJltc4LVdMKHsrFe4MGNPp0hqDFA1Wpt3jE1gEyM3nKUvOiO//9PheZZHfYRfYl6AwdTH4aTcXSqBerX0ml4A==", + "dev": true, + "optional": true + }, + "@esbuild/linux-ppc64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.17.19.tgz", + "integrity": "sha512-/c/DGybs95WXNS8y3Ti/ytqETiW7EU44MEKuCAcpPto3YjQbyK3IQVKfF6nbghD7EcLUGl0NbiL5Rt5DMhn5tg==", + "dev": true, + "optional": true + }, + "@esbuild/linux-riscv64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.17.19.tgz", + "integrity": "sha512-FC3nUAWhvFoutlhAkgHf8f5HwFWUL6bYdvLc/TTuxKlvLi3+pPzdZiFKSWz/PF30TB1K19SuCxDTI5KcqASJqA==", + "dev": true, + "optional": true + }, + "@esbuild/linux-s390x": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.17.19.tgz", + "integrity": "sha512-IbFsFbxMWLuKEbH+7sTkKzL6NJmG2vRyy6K7JJo55w+8xDk7RElYn6xvXtDW8HCfoKBFK69f3pgBJSUSQPr+4Q==", + "dev": true, + "optional": true + }, + "@esbuild/linux-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.17.19.tgz", + "integrity": "sha512-68ngA9lg2H6zkZcyp22tsVt38mlhWde8l3eJLWkyLrp4HwMUr3c1s/M2t7+kHIhvMjglIBrFpncX1SzMckomGw==", + "dev": true, + "optional": true + }, + "@esbuild/netbsd-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.17.19.tgz", + "integrity": "sha512-CwFq42rXCR8TYIjIfpXCbRX0rp1jo6cPIUPSaWwzbVI4aOfX96OXY8M6KNmtPcg7QjYeDmN+DD0Wp3LaBOLf4Q==", + "dev": true, + "optional": true + }, + "@esbuild/openbsd-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.17.19.tgz", + "integrity": "sha512-cnq5brJYrSZ2CF6c35eCmviIN3k3RczmHz8eYaVlNasVqsNY+JKohZU5MKmaOI+KkllCdzOKKdPs762VCPC20g==", + "dev": true, + "optional": true + }, + "@esbuild/sunos-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.17.19.tgz", + "integrity": "sha512-vCRT7yP3zX+bKWFeP/zdS6SqdWB8OIpaRq/mbXQxTGHnIxspRtigpkUcDMlSCOejlHowLqII7K2JKevwyRP2rg==", + "dev": true, + "optional": true + }, + "@esbuild/win32-arm64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.17.19.tgz", + "integrity": "sha512-yYx+8jwowUstVdorcMdNlzklLYhPxjniHWFKgRqH7IFlUEa0Umu3KuYplf1HUZZ422e3NU9F4LGb+4O0Kdcaag==", + "dev": true, + "optional": true + }, + "@esbuild/win32-ia32": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.17.19.tgz", + "integrity": "sha512-eggDKanJszUtCdlVs0RB+h35wNlb5v4TWEkq4vZcmVt5u/HiDZrTXe2bWFQUez3RgNHwx/x4sk5++4NSSicKkw==", + "dev": true, + "optional": true + }, + "@esbuild/win32-x64": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.17.19.tgz", + "integrity": "sha512-lAhycmKnVOuRYNtRtatQR1LPQf2oYCkRGkSFnseDAKPl8lu5SOsK/e1sXe5a0Pc5kHIHe6P2I/ilntNv2xf3cA==", + "dev": true, + "optional": true }, "@eslint-community/eslint-utils": { "version": "4.4.0", @@ -24344,6 +25082,15 @@ } } }, + "@jest/schemas": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/schemas/-/schemas-29.6.3.tgz", + "integrity": "sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==", + "dev": true, + "requires": { + "@sinclair/typebox": "^0.27.8" + } + }, "@jest/source-map": { "version": "26.6.2", "resolved": "https://registry.npmjs.org/@jest/source-map/-/source-map-26.6.2.tgz", @@ -24481,15 +25228,6 @@ "chalk": "^4.0.0" }, "dependencies": { - "@types/istanbul-reports": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.0.tgz", - "integrity": "sha512-nwKNbvnwJ2/mndE9ItP/zc2TCzw6uuodnF4EHYWD+gCQDVBuRQL5UzbZD0/ezy1iKsFU2ZQiDqg4M9dN4+wZgA==", - "dev": true, - "requires": { - "@types/istanbul-lib-report": "*" - } - }, "ansi-styles": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", @@ -24560,14 +25298,12 @@ "@jridgewell/resolve-uri": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz", - "integrity": "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==", - "devOptional": true + "integrity": "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==" }, "@jridgewell/set-array": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz", - "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==", - "devOptional": true + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", + "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==" }, "@jridgewell/source-map": { "version": "0.3.5", @@ -24595,14 +25331,12 @@ "@jridgewell/sourcemap-codec": { "version": "1.4.14", "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz", - "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==", - "devOptional": true + "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==" }, "@jridgewell/trace-mapping": { - "version": "0.3.19", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.19.tgz", - "integrity": "sha512-kf37QtfW+Hwx/buWGMPcR60iF9ziHa6r/CZJIHbmcm4+0qrXiVdxegAH0F6yddEVQ7zdkjcGCgCzUu+BcbhQxw==", - "devOptional": true, + "version": "0.3.25", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", + "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", "requires": { "@jridgewell/resolve-uri": "^3.1.0", "@jridgewell/sourcemap-codec": "^1.4.14" @@ -24620,54 +25354,46 @@ "dev": true }, "@lingui/babel-plugin-extract-messages": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@lingui/babel-plugin-extract-messages/-/babel-plugin-extract-messages-3.14.0.tgz", - "integrity": "sha512-4lcDgVdjYiObuFdDwnAG3jJxS+d3YLq4i7qywlHgjIqteKUH01S3paJRXhZaPvLGl56HarSq0kt8Pymxw8lOrA==", - "dev": true, - "requires": { - "@babel/generator": "^7.11.6", - "@babel/runtime": "^7.11.2", - "@lingui/conf": "^3.14.0", - "mkdirp": "^1.0.4" - } + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/babel-plugin-extract-messages/-/babel-plugin-extract-messages-4.11.3.tgz", + "integrity": "sha512-wLiquhtxE7qUmoKl4UStFI1XgrCkk9zwxc8z62LPpbutkyxO21B5k8fBUGlgWoKJaXbpvS8VIU8j2663q99JnQ==", + "dev": true }, "@lingui/cli": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@lingui/cli/-/cli-3.14.0.tgz", - "integrity": "sha512-QZURsIf7A97tf28b/ffpeL0DekA6tBmcwnj4FBui1SbQqJw1d4IPg2bUM5VRn3/25vhqpi9Uhx5m9x7Vv8QfCQ==", - "dev": true, - "requires": { - "@babel/generator": "^7.11.6", - "@babel/parser": "^7.11.5", - "@babel/plugin-syntax-jsx": "^7.10.4", - "@babel/runtime": "^7.11.2", - "@babel/types": "^7.11.5", - "@lingui/babel-plugin-extract-messages": "^3.14.0", - "@lingui/conf": "^3.14.0", + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/cli/-/cli-4.11.3.tgz", + "integrity": "sha512-ykJLmQciK81I0Cd/iLg8dSpESV9Hnsbw5+G98IEAf4exvoUGRJ2UzkeNc/HeGx3D5Fg+TI8YNWwCbZ7NAOsDCQ==", + "dev": true, + "requires": { + "@babel/core": "^7.21.0", + "@babel/generator": "^7.21.1", + "@babel/parser": "^7.21.2", + "@babel/runtime": "^7.21.0", + "@babel/types": "^7.21.2", + "@lingui/babel-plugin-extract-messages": "4.11.3", + "@lingui/conf": "4.11.3", + "@lingui/core": "4.11.3", + "@lingui/format-po": "4.11.3", + "@lingui/message-utils": "4.11.3", "babel-plugin-macros": "^3.0.1", - "bcp-47": "^1.0.7", "chalk": "^4.1.0", "chokidar": "3.5.1", - "cli-table": "0.3.6", - "commander": "^6.1.0", - "date-fns": "^2.16.1", - "fs-extra": "^9.0.1", - "fuzzaldrin": "^2.1.0", + "cli-table": "^0.3.11", + "commander": "^10.0.0", + "convert-source-map": "^2.0.0", + "date-fns": "^3.6.0", + "esbuild": "^0.17.10", "glob": "^7.1.4", "inquirer": "^7.3.3", - "make-plural": "^6.2.2", - "messageformat-parser": "^4.1.3", "micromatch": "4.0.2", - "mkdirp": "^1.0.4", - "node-gettext": "^3.0.0", "normalize-path": "^3.0.0", "ora": "^5.1.0", - "papaparse": "^5.3.0", + "pathe": "^1.1.0", "pkg-up": "^3.1.0", - "plurals-cldr": "^1.0.4", - "pofile": "^1.1.0", - "pseudolocale": "^1.1.0", - "ramda": "^0.27.1" + "pofile": "^1.1.4", + "pseudolocale": "^2.0.0", + "ramda": "^0.27.1", + "source-map": "^0.8.0-beta.0" }, "dependencies": { "ansi-styles": { @@ -24704,17 +25430,26 @@ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true }, + "convert-source-map": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", + "integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==", + "dev": true + }, "has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true }, - "make-plural": { - "version": "6.2.2", - "resolved": "https://registry.npmjs.org/make-plural/-/make-plural-6.2.2.tgz", - "integrity": "sha512-8iTuFioatnTTmb/YJjywkVIHLjcwkFD9Ms0JpxjEm9Mo8eQYkh1z+55dwv4yc1jQ8ftVBxWQbihvZL1DfzGGWA==", - "dev": true + "source-map": { + "version": "0.8.0-beta.0", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.8.0-beta.0.tgz", + "integrity": "sha512-2ymg6oRBpebeZi9UUNsgQ89bhx01TcTkmNTGnNO88imTmbSgy4nfujrgVEFKWpMTEGA11EDkTt7mqObTPdigIA==", + "dev": true, + "requires": { + "whatwg-url": "^7.0.0" + } }, "supports-color": { "version": "7.2.0", @@ -24724,23 +25459,72 @@ "requires": { "has-flag": "^4.0.0" } + }, + "tr46": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-1.0.1.tgz", + "integrity": "sha512-dTpowEjclQ7Kgx5SdBkqRzVhERQXov8/l9Ft9dVM9fmg0W0KQSVaXX9T4i6twCPNtYiZM53lpSSUAwJbFPOHxA==", + "dev": true, + "requires": { + "punycode": "^2.1.0" + } + }, + "webidl-conversions": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-4.0.2.tgz", + "integrity": "sha512-YQ+BmxuTgd6UXZW3+ICGfyqRyHXVlD5GtQr5+qjiNW7bF0cqrzX500HVXPBOvgXb5YnzDd+h0zqyv61KUD7+Sg==", + "dev": true + }, + "whatwg-url": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-7.1.0.tgz", + "integrity": "sha512-WUu7Rg1DroM7oQvGWfOiAK21n74Gg+T4elXEQYkOhtyLeWiJFoOGLXPKI/9gzIie9CtwVLm8wtw6YJdKyxSjeg==", + "dev": true, + "requires": { + "lodash.sortby": "^4.7.0", + "tr46": "^1.0.1", + "webidl-conversions": "^4.0.2" + } } } }, "@lingui/conf": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@lingui/conf/-/conf-3.14.0.tgz", - "integrity": "sha512-5GMAbIRad9FavqYsfZCRAwjcOLzE7tONDJe9lSYE5SSJbbG01RI5kR5P0B84DUhTI6cGXau+1dAcP9K+JbEx+g==", + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/conf/-/conf-4.11.3.tgz", + "integrity": "sha512-KwUJDrbzlZEXmlmqttpB/Sd9hiIo0sqccsZaYTHzW/uULZT9T11aw/f6RcPLCVJeSKazg/7dJhR1cKlxKzvjKA==", "dev": true, "requires": { - "@babel/runtime": "^7.11.2", - "@endemolshinegroup/cosmiconfig-typescript-loader": "^3.0.2", + "@babel/runtime": "^7.20.13", "chalk": "^4.1.0", - "cosmiconfig": "^7.0.0", - "jest-validate": "^26.5.2", + "cosmiconfig": "^8.0.0", + "jest-validate": "^29.4.3", + "jiti": "^1.17.1", "lodash.get": "^4.4.2" }, "dependencies": { + "@jest/types": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/@jest/types/-/types-29.6.3.tgz", + "integrity": "sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw==", + "dev": true, + "requires": { + "@jest/schemas": "^29.6.3", + "@types/istanbul-lib-coverage": "^2.0.0", + "@types/istanbul-reports": "^3.0.0", + "@types/node": "*", + "@types/yargs": "^17.0.8", + "chalk": "^4.0.0" + } + }, + "@types/yargs": { + "version": "17.0.33", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-17.0.33.tgz", + "integrity": "sha512-WpxBCKWPLr4xSsHgz511rFJAM+wS28w2zEO1QDNY5zM/S8ok70NNfztH0xwhqKyaK0OHCbN98LDAZuy1ctxDkA==", + "dev": true, + "requires": { + "@types/yargs-parser": "*" + } + }, "ansi-styles": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", @@ -24750,6 +25534,12 @@ "color-convert": "^2.0.1" } }, + "argparse": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", + "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", + "dev": true + }, "chalk": { "version": "4.1.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", @@ -24775,12 +25565,78 @@ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true }, + "cosmiconfig": { + "version": "8.3.6", + "resolved": "https://registry.npmjs.org/cosmiconfig/-/cosmiconfig-8.3.6.tgz", + "integrity": "sha512-kcZ6+W5QzcJ3P1Mt+83OUv/oHFqZHIx8DuxG6eZ5RGMERoLqp4BuGjhHLYGK+Kf5XVkQvqBSmAy/nGWN3qDgEA==", + "dev": true, + "requires": { + "import-fresh": "^3.3.0", + "js-yaml": "^4.1.0", + "parse-json": "^5.2.0", + "path-type": "^4.0.0" + } + }, "has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true }, + "jest-get-type": { + "version": "29.6.3", + "resolved": "https://registry.npmjs.org/jest-get-type/-/jest-get-type-29.6.3.tgz", + "integrity": "sha512-zrteXnqYxfQh7l5FHyL38jL39di8H8rHoecLH3JNxH3BwOrBsNeabdap5e0I23lD4HHI8W5VFBZqG4Eaq5LNcw==", + "dev": true + }, + "jest-validate": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-29.7.0.tgz", + "integrity": "sha512-ZB7wHqaRGVw/9hST/OuFUReG7M8vKeq0/J2egIGLdvjHCmYqGARhzXmtgi+gVeZ5uXFF219aOc3Ls2yLg27tkw==", + "dev": true, + "requires": { + "@jest/types": "^29.6.3", + "camelcase": "^6.2.0", + "chalk": "^4.0.0", + "jest-get-type": "^29.6.3", + "leven": "^3.1.0", + "pretty-format": "^29.7.0" + } + }, + "js-yaml": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", + "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", + "dev": true, + "requires": { + "argparse": "^2.0.1" + } + }, + "pretty-format": { + "version": "29.7.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-29.7.0.tgz", + "integrity": "sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ==", + "dev": true, + "requires": { + "@jest/schemas": "^29.6.3", + "ansi-styles": "^5.0.0", + "react-is": "^18.0.0" + }, + "dependencies": { + "ansi-styles": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-5.2.0.tgz", + "integrity": "sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==", + "dev": true + } + } + }, + "react-is": { + "version": "18.3.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz", + "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==", + "dev": true + }, "supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", @@ -24789,57 +25645,87 @@ "requires": { "has-flag": "^4.0.0" } + }, + "typescript": { + "version": "5.5.4", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.5.4.tgz", + "integrity": "sha512-Mtq29sKDAEYP7aljRgtPOpTvOfbwRWlS6dPRzwjdE+C0R4brX/GUyhHSecbHMFLNBLcJIPt9nl9yG5TZ1weH+Q==", + "dev": true, + "optional": true, + "peer": true } } }, "@lingui/core": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@lingui/core/-/core-3.14.0.tgz", - "integrity": "sha512-ertREq9oi9B/umxpd/pInm9uFO8FLK2/0FXfDmMqvH5ydswWn/c9nY5YO4W1h4/8LWO45mewypOIyjoue4De1w==", + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/core/-/core-4.11.3.tgz", + "integrity": "sha512-IjJxn0Kvzv+ICnGlMqn8wRIQLikCJVrolb1oyi6GqtbiuPiwKYeU0D6Hbe146lMaTN8juc3tOCBS+Fr02XqFIQ==", "requires": { - "@babel/runtime": "^7.11.2", - "make-plural": "^6.2.2", - "messageformat-parser": "^4.1.3" - }, - "dependencies": { - "make-plural": { - "version": "6.2.2", - "resolved": "https://registry.npmjs.org/make-plural/-/make-plural-6.2.2.tgz", - "integrity": "sha512-8iTuFioatnTTmb/YJjywkVIHLjcwkFD9Ms0JpxjEm9Mo8eQYkh1z+55dwv4yc1jQ8ftVBxWQbihvZL1DfzGGWA==" - } + "@babel/runtime": "^7.20.13", + "@lingui/message-utils": "4.11.3", + "unraw": "^3.0.0" + } + }, + "@lingui/format-po": { + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/format-po/-/format-po-4.11.3.tgz", + "integrity": "sha512-RgEkoo0aEAk7X1xGrApcpqkz6GLdzkRLGw2jo3mmCVR0P7P9sWbJL/cd01GmR+HzAOo8Zx5oIayaKh9iyJS8tA==", + "dev": true, + "requires": { + "@lingui/conf": "4.11.3", + "@lingui/message-utils": "4.11.3", + "date-fns": "^3.6.0", + "pofile": "^1.1.4" } }, "@lingui/loader": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@lingui/loader/-/loader-3.14.0.tgz", - "integrity": "sha512-FH14MexRLM8tBgSL1oK5dbaUBbY0P85CSLTNwFqAtFFj8K8wWxfdq4+rIkp/kSD+eggKNDYV4G89N9/3bsm3gQ==", + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/loader/-/loader-4.11.3.tgz", + "integrity": "sha512-K0482e0d+KRlljylkOAp6DkOKHboevAqR2nRRipwa8BGV1nJsnSwkvrlny+/OazZK0Dvr7w6tmBODx8KS318Ng==", "dev": true, "requires": { - "@babel/runtime": "^7.11.2", - "@lingui/cli": "^3.14.0", - "@lingui/conf": "^3.14.0", - "loader-utils": "^2.0.0", - "ramda": "^0.27.1" + "@babel/runtime": "^7.20.13", + "@lingui/cli": "4.11.3", + "@lingui/conf": "4.11.3" } }, "@lingui/macro": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@lingui/macro/-/macro-3.14.0.tgz", - "integrity": "sha512-NxTRrhrZ/cUO9PX/4vWys90Ku58+ExxHuE30IuDnnDldWhWlOdycmjDt9tB+yIiUdFym/veSxBs+h114FzG5mA==", + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/macro/-/macro-4.11.3.tgz", + "integrity": "sha512-D0me8ZRtH0ylSavhKZu0FYf5mJ1y6kDMMPjYVDyiT5ooOI/5jjv9LIAqrdYGCBygnwsxOG1dzDw6+3s5GTs+Bg==", "dev": true, "requires": { - "@babel/runtime": "^7.11.2", - "@lingui/conf": "^3.14.0", - "ramda": "^0.27.1" + "@babel/runtime": "^7.20.13", + "@babel/types": "^7.20.7", + "@lingui/conf": "4.11.3", + "@lingui/core": "4.11.3", + "@lingui/message-utils": "4.11.3" + } + }, + "@lingui/message-utils": { + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/message-utils/-/message-utils-4.11.3.tgz", + "integrity": "sha512-ZSw3OoKbknOw3nSrqt194g2F8r0guKow9csb46zlL7zX/yOWCaj767wvSvMoglZtVvurfQs4NPv2cohYlWORNw==", + "requires": { + "@messageformat/parser": "^5.0.0", + "js-sha256": "^0.10.1" } }, "@lingui/react": { - "version": "3.14.0", - "resolved": "https://registry.npmjs.org/@lingui/react/-/react-3.14.0.tgz", - "integrity": "sha512-ow9Mtru7f0T2S9AwnPWRejppcucCW0LmoDR3P4wqHjL+eH5f8a6nxd2doxGieC91/2i4qqW88y4K/zXJxwRSQw==", + "version": "4.11.3", + "resolved": "https://registry.npmjs.org/@lingui/react/-/react-4.11.3.tgz", + "integrity": "sha512-FuorwDsz5zDpUNpyj7J8ZKqJrrVxOz1EtQ3aJGJsmnTtVO01N3nR3ckMzpYvZ71XXdDEvhUC9ihmiKbFvpaZ/w==", + "requires": { + "@babel/runtime": "^7.20.13", + "@lingui/core": "4.11.3" + } + }, + "@messageformat/parser": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@messageformat/parser/-/parser-5.1.0.tgz", + "integrity": "sha512-jKlkls3Gewgw6qMjKZ9SFfHUpdzEVdovKFtW1qRhJ3WI4FW5R/NnGDqr8SDGz+krWDO3ki94boMmQvGke1HwUQ==", "requires": { - "@babel/runtime": "^7.11.2", - "@lingui/core": "^3.14.0" + "moo": "^0.5.1" } }, "@nicolo-ribaudo/chokidar-2": { @@ -24944,6 +25830,12 @@ "integrity": "sha512-Vvn3zZrhQZkkBE8LSuW3em98c0FwgO4nxzv6OdSxPKJIEKY2bGbHn+mhGIPerzI4twdxaP8/0+06HBpwf345Lw==", "dev": true }, + "@sinclair/typebox": { + "version": "0.27.8", + "resolved": "https://registry.npmjs.org/@sinclair/typebox/-/typebox-0.27.8.tgz", + "integrity": "sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==", + "dev": true + }, "@sinonjs/commons": { "version": "1.8.2", "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-1.8.2.tgz", @@ -25323,30 +26215,10 @@ "resolved": "https://registry.npmjs.org/@types/d3-time-format/-/d3-time-format-2.1.0.tgz", "integrity": "sha512-/myT3I7EwlukNOX2xVdMzb8FRgNzRMpsZddwst9Ld/VFe6LyJyRp0s32l/V9XoUzk+Gqu56F/oGk6507+8BxrA==" }, - "@types/eslint": { - "version": "8.4.5", - "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-8.4.5.tgz", - "integrity": "sha512-dhsC09y1gpJWnK+Ff4SGvCuSnk9DaU0BJZSzOwa6GVSg65XtTugLBITDAAzRU5duGBoXBHpdR/9jHGxJjNflJQ==", - "dev": true, - "requires": { - "@types/estree": "*", - "@types/json-schema": "*" - } - }, - "@types/eslint-scope": { - "version": "3.7.4", - "resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.4.tgz", - "integrity": "sha512-9K4zoImiZc3HlIp6AVUDE4CWYx22a+lhSZMYNpbjW04+YF0KWj4pJXnEMjdnFTiQibFFmElcsasJXDbdI/EPhA==", - "dev": true, - "requires": { - "@types/eslint": "*", - "@types/estree": "*" - } - }, "@types/estree": { - "version": "0.0.51", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-0.0.51.tgz", - "integrity": "sha512-CuPgU6f3eT/XgKKPqKd/gLZV1Xmvf1a2R5POBOGQa6uv82xpls89HU5zKeVoyR8XzHd1RGNOlQlvUe3CFkjWNQ==", + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz", + "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==", "dev": true }, "@types/express": { @@ -25426,6 +26298,15 @@ "@types/istanbul-lib-coverage": "*" } }, + "@types/istanbul-reports": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz", + "integrity": "sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ==", + "dev": true, + "requires": { + "@types/istanbul-lib-report": "*" + } + }, "@types/jest": { "version": "26.0.15", "resolved": "https://registry.npmjs.org/@types/jest/-/jest-26.0.15.tgz", @@ -26194,148 +27075,148 @@ } }, "@webassemblyjs/ast": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.11.1.tgz", - "integrity": "sha512-ukBh14qFLjxTQNTXocdyksN5QdM28S1CxHt2rdskFyL+xFV7VremuBLVbmCePj+URalXBENx/9Lm7lnhihtCSw==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.12.1.tgz", + "integrity": "sha512-EKfMUOPRRUTy5UII4qJDGPpqfwjOmZ5jeGFwid9mnoqIFK+e0vqoi1qH56JpmZSzEL53jKnNzScdmftJyG5xWg==", "dev": true, "requires": { - "@webassemblyjs/helper-numbers": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1" + "@webassemblyjs/helper-numbers": "1.11.6", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6" } }, "@webassemblyjs/floating-point-hex-parser": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.11.1.tgz", - "integrity": "sha512-iGRfyc5Bq+NnNuX8b5hwBrRjzf0ocrJPI6GWFodBFzmFnyvrQ83SHKhmilCU/8Jv67i4GJZBMhEzltxzcNagtQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.11.6.tgz", + "integrity": "sha512-ejAj9hfRJ2XMsNHk/v6Fu2dGS+i4UaXBXGemOfQ/JfQ6mdQg/WXtwleQRLLS4OvfDhv8rYnVwH27YJLMyYsxhw==", "dev": true }, "@webassemblyjs/helper-api-error": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.11.1.tgz", - "integrity": "sha512-RlhS8CBCXfRUR/cwo2ho9bkheSXG0+NwooXcc3PAILALf2QLdFyj7KGsKRbVc95hZnhnERon4kW/D3SZpp6Tcg==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.11.6.tgz", + "integrity": "sha512-o0YkoP4pVu4rN8aTJgAyj9hC2Sv5UlkzCHhxqWj8butaLvnpdc2jOwh4ewE6CX0txSfLn/UYaV/pheS2Txg//Q==", "dev": true }, "@webassemblyjs/helper-buffer": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.11.1.tgz", - "integrity": "sha512-gwikF65aDNeeXa8JxXa2BAk+REjSyhrNC9ZwdT0f8jc4dQQeDQ7G4m0f2QCLPJiMTTO6wfDmRmj/pW0PsUvIcA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.12.1.tgz", + "integrity": "sha512-nzJwQw99DNDKr9BVCOZcLuJJUlqkJh+kVzVl6Fmq/tI5ZtEyWT1KZMyOXltXLZJmDtvLCDgwsyrkohEtopTXCw==", "dev": true }, "@webassemblyjs/helper-numbers": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-numbers/-/helper-numbers-1.11.1.tgz", - "integrity": "sha512-vDkbxiB8zfnPdNK9Rajcey5C0w+QJugEglN0of+kmO8l7lDb77AnlKYQF7aarZuCrv+l0UvqL+68gSDr3k9LPQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-numbers/-/helper-numbers-1.11.6.tgz", + "integrity": "sha512-vUIhZ8LZoIWHBohiEObxVm6hwP034jwmc9kuq5GdHZH0wiLVLIPcMCdpJzG4C11cHoQ25TFIQj9kaVADVX7N3g==", "dev": true, "requires": { - "@webassemblyjs/floating-point-hex-parser": "1.11.1", - "@webassemblyjs/helper-api-error": "1.11.1", + "@webassemblyjs/floating-point-hex-parser": "1.11.6", + "@webassemblyjs/helper-api-error": "1.11.6", "@xtuc/long": "4.2.2" } }, "@webassemblyjs/helper-wasm-bytecode": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.11.1.tgz", - "integrity": "sha512-PvpoOGiJwXeTrSf/qfudJhwlvDQxFgelbMqtq52WWiXC6Xgg1IREdngmPN3bs4RoO83PnL/nFrxucXj1+BX62Q==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.11.6.tgz", + "integrity": "sha512-sFFHKwcmBprO9e7Icf0+gddyWYDViL8bpPjJJl0WHxCdETktXdmtWLGVzoHbqUcY4Be1LkNfwTmXOJUFZYSJdA==", "dev": true }, "@webassemblyjs/helper-wasm-section": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.11.1.tgz", - "integrity": "sha512-10P9No29rYX1j7F3EVPX3JvGPQPae+AomuSTPiF9eBQeChHI6iqjMIwR9JmOJXwpnn/oVGDk7I5IlskuMwU/pg==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.12.1.tgz", + "integrity": "sha512-Jif4vfB6FJlUlSbgEMHUyk1j234GTNG9dBJ4XJdOySoj518Xj0oGsNi59cUQF4RRMS9ouBUxDDdyBVfPTypa5g==", "dev": true, "requires": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-buffer": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/wasm-gen": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/wasm-gen": "1.12.1" } }, "@webassemblyjs/ieee754": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.11.1.tgz", - "integrity": "sha512-hJ87QIPtAMKbFq6CGTkZYJivEwZDbQUgYd3qKSadTNOhVY7p+gfP6Sr0lLRVTaG1JjFj+r3YchoqRYxNH3M0GQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.11.6.tgz", + "integrity": "sha512-LM4p2csPNvbij6U1f19v6WR56QZ8JcHg3QIJTlSwzFcmx6WSORicYj6I63f9yU1kEUtrpG+kjkiIAkevHpDXrg==", "dev": true, "requires": { "@xtuc/ieee754": "^1.2.0" } }, "@webassemblyjs/leb128": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.11.1.tgz", - "integrity": "sha512-BJ2P0hNZ0u+Th1YZXJpzW6miwqQUGcIHT1G/sf72gLVD9DZ5AdYTqPNbHZh6K1M5VmKvFXwGSWZADz+qBWxeRw==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.11.6.tgz", + "integrity": "sha512-m7a0FhE67DQXgouf1tbN5XQcdWoNgaAuoULHIfGFIEVKA6tu/edls6XnIlkmS6FrXAquJRPni3ZZKjw6FSPjPQ==", "dev": true, "requires": { "@xtuc/long": "4.2.2" } }, "@webassemblyjs/utf8": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.11.1.tgz", - "integrity": "sha512-9kqcxAEdMhiwQkHpkNiorZzqpGrodQQ2IGrHHxCy+Ozng0ofyMA0lTqiLkVs1uzTRejX+/O0EOT7KxqVPuXosQ==", + "version": "1.11.6", + "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.11.6.tgz", + "integrity": "sha512-vtXf2wTQ3+up9Zsg8sa2yWiQpzSsMyXj0qViVP6xKGCUT8p8YJ6HqI7l5eCnWx1T/FYdsv07HQs2wTFbbof/RA==", "dev": true }, "@webassemblyjs/wasm-edit": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.11.1.tgz", - "integrity": "sha512-g+RsupUC1aTHfR8CDgnsVRVZFJqdkFHpsHMfJuWQzWU3tvnLC07UqHICfP+4XyL2tnr1amvl1Sdp06TnYCmVkA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.12.1.tgz", + "integrity": "sha512-1DuwbVvADvS5mGnXbE+c9NfA8QRcZ6iKquqjjmR10k6o+zzsRVesil54DKexiowcFCPdr/Q0qaMgB01+SQ1u6g==", "dev": true, "requires": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-buffer": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/helper-wasm-section": "1.11.1", - "@webassemblyjs/wasm-gen": "1.11.1", - "@webassemblyjs/wasm-opt": "1.11.1", - "@webassemblyjs/wasm-parser": "1.11.1", - "@webassemblyjs/wast-printer": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/helper-wasm-section": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-opt": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1", + "@webassemblyjs/wast-printer": "1.12.1" } }, "@webassemblyjs/wasm-gen": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.11.1.tgz", - "integrity": "sha512-F7QqKXwwNlMmsulj6+O7r4mmtAlCWfO/0HdgOxSklZfQcDu0TpLiD1mRt/zF25Bk59FIjEuGAIyn5ei4yMfLhA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.12.1.tgz", + "integrity": "sha512-TDq4Ojh9fcohAw6OIMXqiIcTq5KUXTGRkVxbSo1hQnSy6lAM5GSdfwWeSxpAo0YzgsgF182E/U0mDNhuA0tW7w==", "dev": true, "requires": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/ieee754": "1.11.1", - "@webassemblyjs/leb128": "1.11.1", - "@webassemblyjs/utf8": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/ieee754": "1.11.6", + "@webassemblyjs/leb128": "1.11.6", + "@webassemblyjs/utf8": "1.11.6" } }, "@webassemblyjs/wasm-opt": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.11.1.tgz", - "integrity": "sha512-VqnkNqnZlU5EB64pp1l7hdm3hmQw7Vgqa0KF/KCNO9sIpI6Fk6brDEiX+iCOYrvMuBWDws0NkTOxYEb85XQHHw==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.12.1.tgz", + "integrity": "sha512-Jg99j/2gG2iaz3hijw857AVYekZe2SAskcqlWIZXjji5WStnOpVoat3gQfT/Q5tb2djnCjBtMocY/Su1GfxPBg==", "dev": true, "requires": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-buffer": "1.11.1", - "@webassemblyjs/wasm-gen": "1.11.1", - "@webassemblyjs/wasm-parser": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-buffer": "1.12.1", + "@webassemblyjs/wasm-gen": "1.12.1", + "@webassemblyjs/wasm-parser": "1.12.1" } }, "@webassemblyjs/wasm-parser": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.11.1.tgz", - "integrity": "sha512-rrBujw+dJu32gYB7/Lup6UhdkPx9S9SnobZzRVL7VcBH9Bt9bCBLEuX/YXOOtBsOZ4NQrRykKhffRWHvigQvOA==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.12.1.tgz", + "integrity": "sha512-xikIi7c2FHXysxXe3COrVUPSheuBtpcfhbpFj4gmu7KRLYOzANztwUU0IbsqvMqzuNK2+glRGWCEqZo1WCLyAQ==", "dev": true, "requires": { - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/helper-api-error": "1.11.1", - "@webassemblyjs/helper-wasm-bytecode": "1.11.1", - "@webassemblyjs/ieee754": "1.11.1", - "@webassemblyjs/leb128": "1.11.1", - "@webassemblyjs/utf8": "1.11.1" + "@webassemblyjs/ast": "1.12.1", + "@webassemblyjs/helper-api-error": "1.11.6", + "@webassemblyjs/helper-wasm-bytecode": "1.11.6", + "@webassemblyjs/ieee754": "1.11.6", + "@webassemblyjs/leb128": "1.11.6", + "@webassemblyjs/utf8": "1.11.6" } }, "@webassemblyjs/wast-printer": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.11.1.tgz", - "integrity": "sha512-IQboUWM4eKzWW+N/jij2sRatKMh99QEelo3Eb2q0qXkvPRISAj8Qxtmw5itwqK+TTkBuUIE45AxYPToqPtL5gg==", + "version": "1.12.1", + "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.12.1.tgz", + "integrity": "sha512-+X4WAlOisVWQMikjbcvY2e0rwPsKQ9F688lksZhBcPycBBuii3O7m8FACbDMWDojpAqvjIncrG8J0XHKyQfVeA==", "dev": true, "requires": { - "@webassemblyjs/ast": "1.11.1", + "@webassemblyjs/ast": "1.12.1", "@xtuc/long": "4.2.2" } }, @@ -26482,10 +27363,10 @@ } } }, - "acorn-import-assertions": { - "version": "1.8.0", - "resolved": "https://registry.npmjs.org/acorn-import-assertions/-/acorn-import-assertions-1.8.0.tgz", - "integrity": "sha512-m7VZ3jwz4eK6A4Vtt8Ew1/mNbP24u0FhdyfA7fSvnJR6LMdfOYnmuIrrJAgrYfYJ10F/otaHTtrtrtmHdMNzEw==", + "acorn-import-attributes": { + "version": "1.9.5", + "resolved": "https://registry.npmjs.org/acorn-import-attributes/-/acorn-import-attributes-1.9.5.tgz", + "integrity": "sha512-n02Vykv5uA3eHGM/Z2dQrcD56kL8TyDb2p1+0P83PClMnC/nc+anbQRhIOWnSq4Ke/KvDPrY3C9hDtC/A3eHnQ==", "dev": true, "requires": {} }, @@ -26824,12 +27705,6 @@ "apollo-server-env": "^4.2.1" } }, - "arg": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", - "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", - "dev": true - }, "argparse": { "version": "1.0.10", "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", @@ -26973,12 +27848,6 @@ "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=", "dev": true }, - "at-least-node": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/at-least-node/-/at-least-node-1.0.0.tgz", - "integrity": "sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg==", - "dev": true - }, "atob": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz", @@ -27255,17 +28124,6 @@ "integrity": "sha1-3DQxT05nkxgJP8dgJyUl+UvyXBY=", "dev": true }, - "bcp-47": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/bcp-47/-/bcp-47-1.0.8.tgz", - "integrity": "sha512-Y9y1QNBBtYtv7hcmoX0tR+tUNSFZGZ6OL6vKPObq8BbOhkCoyayF6ogfLTgAli/KuAEbsYHYUNq2AQuY6IuLag==", - "dev": true, - "requires": { - "is-alphabetical": "^1.0.0", - "is-alphanumerical": "^1.0.0", - "is-decimal": "^1.0.0" - } - }, "big.js": { "version": "5.2.2", "resolved": "https://registry.npmjs.org/big.js/-/big.js-5.2.2.tgz", @@ -27298,9 +28156,9 @@ } }, "body-parser": { - "version": "1.20.2", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz", - "integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==", + "version": "1.20.3", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", + "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", "requires": { "bytes": "3.1.2", "content-type": "~1.0.5", @@ -27310,7 +28168,7 @@ "http-errors": "2.0.0", "iconv-lite": "0.4.24", "on-finished": "2.4.1", - "qs": "6.11.0", + "qs": "6.13.0", "raw-body": "2.5.2", "type-is": "~1.6.18", "unpipe": "1.0.0" @@ -27320,6 +28178,14 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==" + }, + "qs": { + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz", + "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==", + "requires": { + "side-channel": "^1.0.6" + } } } }, @@ -27375,15 +28241,15 @@ "dev": true }, "browserslist": { - "version": "4.22.2", - "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.22.2.tgz", - "integrity": "sha512-0UgcrvQmBDvZHFGdYUehrCNIazki7/lUP3kkoi/r3YB2amZbFM9J43ZRkJTXBUZK4gmx56+Sqk9+Vs9mwZx9+A==", + "version": "4.23.3", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.23.3.tgz", + "integrity": "sha512-btwCFJVjI4YWDNfau8RhZ+B1Q/VLoUITrm3RlP6y1tYGWIOa+InuYiRGXUBXo8nA1qKmHMyLB/iVQg5TT4eFoA==", "devOptional": true, "requires": { - "caniuse-lite": "^1.0.30001565", - "electron-to-chromium": "^1.4.601", - "node-releases": "^2.0.14", - "update-browserslist-db": "^1.0.13" + "caniuse-lite": "^1.0.30001646", + "electron-to-chromium": "^1.5.4", + "node-releases": "^2.0.18", + "update-browserslist-db": "^1.1.0" } }, "bser": { @@ -27440,12 +28306,15 @@ } }, "call-bind": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", - "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.7.tgz", + "integrity": "sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==", "requires": { - "function-bind": "^1.1.1", - "get-intrinsic": "^1.0.2" + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "set-function-length": "^1.2.1" } }, "callsites": { @@ -27478,9 +28347,9 @@ "dev": true }, "caniuse-lite": { - "version": "1.0.30001572", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001572.tgz", - "integrity": "sha512-1Pbh5FLmn5y4+QhNyJE9j3/7dK44dGB83/ZMjv/qJk86TvDbjk0LosiZo0i0WB0Vx607qMX9jYrn1VLHCkN4rw==", + "version": "1.0.30001653", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001653.tgz", + "integrity": "sha512-XGWQVB8wFQ2+9NZwZ10GxTYC5hk0Fa+q8cSkr0tgvMhYhMHP/QC+WTgrePMDBWiWc/pV+1ik82Al20XOK25Gcw==", "devOptional": true }, "capture-exit": { @@ -27633,9 +28502,9 @@ "dev": true }, "cli-table": { - "version": "0.3.6", - "resolved": "https://registry.npmjs.org/cli-table/-/cli-table-0.3.6.tgz", - "integrity": "sha512-ZkNZbnZjKERTY5NwC2SeMeLeifSPq/pubeRoTpdr3WchLlnZg6hEgvHkK5zL7KNFdd9PmHN8lxrENUwI3cE8vQ==", + "version": "0.3.11", + "resolved": "https://registry.npmjs.org/cli-table/-/cli-table-0.3.11.tgz", + "integrity": "sha512-IqLQi4lO0nIB4tcdTpN4LCB9FI3uqrJZK7RC515EnhZ6qBaglkIgICb1wjeAqpdoOabm1+SuQtkXIPdYC93jhQ==", "dev": true, "requires": { "colors": "1.4.0" @@ -27737,9 +28606,9 @@ } }, "commander": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/commander/-/commander-6.2.1.tgz", - "integrity": "sha512-U7VdrJFnJgo4xjrHpTzu0yrHPGImdsmD95ZlgYSEajAn2JKzDhDTPG9kBTefmObL2w/ngeZnilk+OV9CG3d7UA==", + "version": "10.0.1", + "resolved": "https://registry.npmjs.org/commander/-/commander-10.0.1.tgz", + "integrity": "sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug==", "dev": true }, "commondir": { @@ -27895,12 +28764,6 @@ "yaml": "^1.10.0" } }, - "create-require": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz", - "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==", - "dev": true - }, "cross-spawn": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", @@ -28317,9 +29180,9 @@ } }, "date-fns": { - "version": "2.16.1", - "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-2.16.1.tgz", - "integrity": "sha512-sAJVKx/FqrLYHAQeN7VpJrPhagZc9R4ImZIWYRFZaaohR3KzmuK88touwsSwSVT8Qcbd4zoDsnGfX4GFB4imyQ==", + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-3.6.0.tgz", + "integrity": "sha512-fRHTG8g/Gif+kSh50gaGEdToemgfj74aRX3swtiouboip5JDLAyDE9F11nHMIcvOaXeOC6D7SpNhi7uFyB7Uww==", "dev": true }, "debounce": { @@ -28433,6 +29296,16 @@ "clone": "^1.0.2" } }, + "define-data-property": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", + "integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==", + "requires": { + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "gopd": "^1.0.1" + } + }, "define-lazy-prop": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/define-lazy-prop/-/define-lazy-prop-2.0.0.tgz", @@ -28557,12 +29430,6 @@ "wrappy": "1" } }, - "diff": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", - "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", - "dev": true - }, "diff-sequences": { "version": "26.6.2", "resolved": "https://registry.npmjs.org/diff-sequences/-/diff-sequences-26.6.2.tgz", @@ -28726,9 +29593,9 @@ "integrity": "sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0=" }, "electron-to-chromium": { - "version": "1.4.616", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.616.tgz", - "integrity": "sha512-1n7zWYh8eS0L9Uy+GskE0lkBUNK83cXTVJI0pU3mGprFsbfSdAc15VTFbo+A+Bq4pwstmL30AVcEU3Fo463lNg==", + "version": "1.5.13", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.13.tgz", + "integrity": "sha512-lbBcvtIJ4J6sS4tb5TLp1b4LyfCdMkwStzXPyAgVgTRAsep4bvrAGaBOP7ZJtQMNJpSQ9SqG4brWOroNaQtm7Q==", "devOptional": true }, "emittery": { @@ -28764,9 +29631,9 @@ } }, "enhanced-resolve": { - "version": "5.10.0", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.10.0.tgz", - "integrity": "sha512-T0yTFjdpldGY8PmuXXR0PyQ1ufZpEGiHVrp7zHKB7jdR4qlmZHhONVM5AQOAWXuF/w3dnHbEQVrNptJgt7F+cQ==", + "version": "5.17.1", + "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.17.1.tgz", + "integrity": "sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg==", "dev": true, "requires": { "graceful-fs": "^4.2.4", @@ -28840,10 +29707,23 @@ "unbox-primitive": "^1.0.2" } }, + "es-define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.0.tgz", + "integrity": "sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==", + "requires": { + "get-intrinsic": "^1.2.4" + } + }, + "es-errors": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", + "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==" + }, "es-module-lexer": { - "version": "0.9.3", - "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-0.9.3.tgz", - "integrity": "sha512-1HQ2M2sPtxwnvOvT1ZClHyQDiggdNjURWpY2we6aMKCQiUVxTmVs2UYPLIrD84sS+kMdUwfBSylbJPwNnBrnHQ==", + "version": "1.5.4", + "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.5.4.tgz", + "integrity": "sha512-MVNK56NiMrOwitFB7cqDwq0CQutbw+0BvLshJSse0MUNU+y1FC3bUS/AQg7oUng+/wKrrki7JfmwtVHkVfPLlw==", "dev": true }, "es-shim-unscopables": { @@ -28866,10 +29746,40 @@ "is-symbol": "^1.0.2" } }, + "esbuild": { + "version": "0.17.19", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.17.19.tgz", + "integrity": "sha512-XQ0jAPFkK/u3LcVRcvVHQcTIqD6E2H1fvZMA5dQPSOWb3suUbWbfbRf94pjc0bNzRYLfIrDRQXr7X+LHIm5oHw==", + "dev": true, + "requires": { + "@esbuild/android-arm": "0.17.19", + "@esbuild/android-arm64": "0.17.19", + "@esbuild/android-x64": "0.17.19", + "@esbuild/darwin-arm64": "0.17.19", + "@esbuild/darwin-x64": "0.17.19", + "@esbuild/freebsd-arm64": "0.17.19", + "@esbuild/freebsd-x64": "0.17.19", + "@esbuild/linux-arm": "0.17.19", + "@esbuild/linux-arm64": "0.17.19", + "@esbuild/linux-ia32": "0.17.19", + "@esbuild/linux-loong64": "0.17.19", + "@esbuild/linux-mips64el": "0.17.19", + "@esbuild/linux-ppc64": "0.17.19", + "@esbuild/linux-riscv64": "0.17.19", + "@esbuild/linux-s390x": "0.17.19", + "@esbuild/linux-x64": "0.17.19", + "@esbuild/netbsd-x64": "0.17.19", + "@esbuild/openbsd-x64": "0.17.19", + "@esbuild/sunos-x64": "0.17.19", + "@esbuild/win32-arm64": "0.17.19", + "@esbuild/win32-ia32": "0.17.19", + "@esbuild/win32-x64": "0.17.19" + } + }, "escalade": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", - "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.2.tgz", + "integrity": "sha512-ErCHMCae19vR8vQGe50xIsVomy19rg6gFu3+r3jkEO46suLMWBksvVyoGgQV+jOfl84ZSOSlmv6Gxa89PmTGmA==", "devOptional": true }, "escape-html": { @@ -29420,7 +30330,7 @@ "etag": { "version": "1.8.1", "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", - "integrity": "sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc=" + "integrity": "sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==" }, "eventemitter3": { "version": "4.0.7", @@ -29582,36 +30492,36 @@ } }, "express": { - "version": "4.19.2", - "resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz", - "integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==", + "version": "4.20.0", + "resolved": "https://registry.npmjs.org/express/-/express-4.20.0.tgz", + "integrity": "sha512-pLdae7I6QqShF5PnNTCVn4hI91Dx0Grkn2+IAsMTgMIKuQVte2dN9PeGSSAME2FR8anOhVA62QDIUaWVfEXVLw==", "requires": { "accepts": "~1.3.8", "array-flatten": "1.1.1", - "body-parser": "1.20.2", + "body-parser": "1.20.3", "content-disposition": "0.5.4", "content-type": "~1.0.4", "cookie": "0.6.0", "cookie-signature": "1.0.6", "debug": "2.6.9", "depd": "2.0.0", - "encodeurl": "~1.0.2", + "encodeurl": "~2.0.0", "escape-html": "~1.0.3", "etag": "~1.8.1", "finalhandler": "1.2.0", "fresh": "0.5.2", "http-errors": "2.0.0", - "merge-descriptors": "1.0.1", + "merge-descriptors": "1.0.3", "methods": "~1.1.2", "on-finished": "2.4.1", "parseurl": "~1.3.3", - "path-to-regexp": "0.1.7", + "path-to-regexp": "0.1.10", "proxy-addr": "~2.0.7", "qs": "6.11.0", "range-parser": "~1.2.1", "safe-buffer": "5.2.1", - "send": "0.18.0", - "serve-static": "1.15.0", + "send": "0.19.0", + "serve-static": "1.16.0", "setprototypeof": "1.2.0", "statuses": "2.0.1", "type-is": "~1.6.18", @@ -29624,6 +30534,11 @@ "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==" }, + "encodeurl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", + "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==" + }, "safe-buffer": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", @@ -30093,19 +31008,7 @@ "fresh": { "version": "0.5.2", "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", - "integrity": "sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac=" - }, - "fs-extra": { - "version": "9.0.1", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.0.1.tgz", - "integrity": "sha512-h2iAoN838FqAFJY2/qVpzFXy+EBxfVE220PalAqQLDVsFOHLJrZvut5puAbCdNv6WJk+B8ihI+k0c7JK5erwqQ==", - "dev": true, - "requires": { - "at-least-node": "^1.0.0", - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^1.0.0" - } + "integrity": "sha512-zJ2mQYM18rEFOudeV4GShTGIQ7RbzA7ozbU9I/XBpm7kqgMywgmylMwXHxZJmkVoYkna9d2pVXVXPdYTP9ej8Q==" }, "fs-monkey": { "version": "1.0.3", @@ -30133,9 +31036,9 @@ "optional": true }, "function-bind": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", - "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", + "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==" }, "function.prototype.name": { "version": "1.1.5", @@ -30161,12 +31064,6 @@ "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==", "dev": true }, - "fuzzaldrin": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fuzzaldrin/-/fuzzaldrin-2.1.0.tgz", - "integrity": "sha1-kCBMPi/appQbso0WZF1BgGOpDps=", - "dev": true - }, "gensync": { "version": "1.0.0-beta.2", "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz", @@ -30180,13 +31077,15 @@ "dev": true }, "get-intrinsic": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.1.1.tgz", - "integrity": "sha512-kWZrnVM42QCiEA2Ig1bG8zjoIMOgxWwYCEeNdwY6Tv/cOSeGpcoX4pXHfKUxNKVoArnrEr2e9srnAxxGIraS9Q==", + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.4.tgz", + "integrity": "sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==", "requires": { - "function-bind": "^1.1.1", - "has": "^1.0.3", - "has-symbols": "^1.0.1" + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "hasown": "^2.0.0" } }, "get-nonce": { @@ -30267,8 +31166,7 @@ "globals": { "version": "11.12.0", "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", - "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", - "devOptional": true + "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==" }, "globby": { "version": "6.1.0", @@ -30291,10 +31189,18 @@ } } }, + "gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "requires": { + "get-intrinsic": "^1.1.3" + } + }, "graceful-fs": { - "version": "4.2.9", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.9.tgz", - "integrity": "sha512-NtNxqUcXgpW2iMrfqSfR73Glt39K+BLwWsPs94yR63v45T0Wbej7eRmL5cWfwEgqXnmjQp3zaJTshdRW/qC2ZQ==", + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", "dev": true }, "graphql": { @@ -30366,14 +31272,18 @@ "integrity": "sha1-tdRU3CGZriJWmfNGfloH87lVuv0=" }, "has-property-descriptors": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz", - "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==", - "dev": true, + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz", + "integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==", "requires": { - "get-intrinsic": "^1.1.1" + "es-define-property": "^1.0.0" } }, + "has-proto": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.3.tgz", + "integrity": "sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==" + }, "has-symbols": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", @@ -30440,6 +31350,14 @@ } } }, + "hasown": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", + "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", + "requires": { + "function-bind": "^1.1.2" + } + }, "he": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", @@ -30750,9 +31668,9 @@ "dev": true }, "import-fresh": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.2.1.tgz", - "integrity": "sha512-6e1q1cnWP2RXD9/keSkxHScg508CdXqXWgWBaETNhyuBFz+kUZlKboh+ISK+bU++DmbHimVBrOz/zzPe0sZ3sQ==", + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", + "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==", "requires": { "parent-module": "^1.0.0", "resolve-from": "^4.0.0" @@ -30968,22 +31886,6 @@ } } }, - "is-alphabetical": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-alphabetical/-/is-alphabetical-1.0.4.tgz", - "integrity": "sha512-DwzsA04LQ10FHTZuL0/grVDk4rFoVH1pjAToYwBrHSxcrBIGQuXrQMtD5U1b0U2XVgKZCTLLP8u2Qxqhy3l2Vg==", - "dev": true - }, - "is-alphanumerical": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-alphanumerical/-/is-alphanumerical-1.0.4.tgz", - "integrity": "sha512-UzoZUr+XfVz3t3v4KyGEniVL9BDRoQtY7tOyrRybkVNjDFWyo1yhXNGrrBTQxp3ib9BLAWs7k2YKBQsFRkZG9A==", - "dev": true, - "requires": { - "is-alphabetical": "^1.0.0", - "is-decimal": "^1.0.0" - } - }, "is-bigint": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", @@ -31067,12 +31969,6 @@ "integrity": "sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==", "dev": true }, - "is-decimal": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/is-decimal/-/is-decimal-1.0.4.tgz", - "integrity": "sha512-RGdriMmQQvZ2aqaQq3awNA6dCGtKpiDFcOzrTWrDAT2MiWrKQVPmxLGHl7Y2nNu6led0kEyoX0enY0qXYsv9zw==", - "dev": true - }, "is-descriptor": { "version": "0.1.6", "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", @@ -32715,9 +33611,9 @@ } }, "jest-worker": { - "version": "27.4.2", - "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-27.4.2.tgz", - "integrity": "sha512-0QMy/zPovLfUPyHuOuuU4E+kGACXXE84nRnq6lBVI9GJg5DCBiA97SATi+ZP8CpiJwEQy1oCPjRBf8AnLjN+Ag==", + "version": "27.5.1", + "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-27.5.1.tgz", + "integrity": "sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg==", "dev": true, "requires": { "@types/node": "*", @@ -32742,6 +33638,17 @@ } } }, + "jiti": { + "version": "1.21.6", + "resolved": "https://registry.npmjs.org/jiti/-/jiti-1.21.6.tgz", + "integrity": "sha512-2yTgeWTWzMWkHu6Jp9NKgePDaYHbntiwvYuuJLbbN9vl7DC9DvXKOB2BC3ZZ92D3cvV/aflH0osDfwpHepQ53w==", + "dev": true + }, + "js-sha256": { + "version": "0.10.1", + "resolved": "https://registry.npmjs.org/js-sha256/-/js-sha256-0.10.1.tgz", + "integrity": "sha512-5obBtsz9301ULlsgggLg542s/jqtddfOpV5KJc4hajc9JV8GeY2gZHSVpYBn4nWqAUTJ9v+xwtbJ1mIBgIH5Vw==" + }, "js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", @@ -32795,8 +33702,7 @@ "jsesc": { "version": "2.5.2", "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", - "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", - "devOptional": true + "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==" }, "json-2-csv": { "version": "3.17.1", @@ -32807,16 +33713,10 @@ "doc-path": "3.0.2" } }, - "json-parse-better-errors": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz", - "integrity": "sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw==" - }, "json-parse-even-better-errors": { "version": "2.3.1", "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", - "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", - "dev": true + "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==" }, "json-schema-traverse": { "version": "0.4.1", @@ -32836,16 +33736,6 @@ "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==", "devOptional": true }, - "jsonfile": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.0.1.tgz", - "integrity": "sha512-jR2b5v7d2vIOust+w3wtFKZIfpC2pnRmFAhAC/BuweZFQR8qZzxH1OyrQ10HmdVYiXWkYUqPVsz91cG7EL2FBg==", - "dev": true, - "requires": { - "graceful-fs": "^4.1.6", - "universalify": "^1.0.0" - } - }, "jsonwebtoken": { "version": "9.0.0", "resolved": "https://registry.npmjs.org/jsonwebtoken/-/jsonwebtoken-9.0.0.tgz", @@ -33154,12 +34044,6 @@ } } }, - "make-error": { - "version": "1.3.6", - "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", - "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", - "dev": true - }, "make-plural": { "version": "7.1.0", "resolved": "https://registry.npmjs.org/make-plural/-/make-plural-7.1.0.tgz", @@ -33214,9 +34098,9 @@ "integrity": "sha512-rkpe71W0N0c0Xz6QD0eJETuWAJGnJ9afsl1srmwPrI+yBCkge5EycXXbYRyvL29zZVUWQCY7InPRCv3GDXuZNw==" }, "merge-descriptors": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", - "integrity": "sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E=" + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", + "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==" }, "merge-stream": { "version": "2.0.0", @@ -33230,11 +34114,6 @@ "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", "dev": true }, - "messageformat-parser": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/messageformat-parser/-/messageformat-parser-4.1.3.tgz", - "integrity": "sha512-2fU3XDCanRqeOCkn7R5zW5VQHWf+T3hH65SzuqRvjatBK7r4uyFa5mEX+k6F9Bd04LVM5G4/BHBTUJsOdW7uyg==" - }, "methods": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", @@ -33331,11 +34210,10 @@ } } }, - "mkdirp": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "dev": true + "moo": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/moo/-/moo-0.5.2.tgz", + "integrity": "sha512-iSAJLHYKnX41mKcJKjqvnAN9sf0LMDTXDEvFv+ffuRR9a1MIuXLjMNL6EsnDHSkKLTWNqQQ5uo61P4EbU4NU+Q==" }, "mq-polyfill": { "version": "1.1.8", @@ -33470,15 +34348,6 @@ "integrity": "sha512-dPEtOeMvF9VMcYV/1Wb8CPoVAXtp6MKMlcbAt4ddqmGqUJ6fQZFXkNZNkNlfevtNkGtaSoXf/vNNNSvgrdXwtA==", "dev": true }, - "node-gettext": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/node-gettext/-/node-gettext-3.0.0.tgz", - "integrity": "sha512-/VRYibXmVoN6tnSAY2JWhNRhWYJ8Cd844jrZU/DwLVoI4vBI6ceYbd8i42sYZ9uOgDH3S7vslIKOWV/ZrT2YBA==", - "dev": true, - "requires": { - "lodash.get": "^4.4.2" - } - }, "node-int64": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz", @@ -33519,9 +34388,9 @@ } }, "node-releases": { - "version": "2.0.14", - "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.14.tgz", - "integrity": "sha512-y10wOWt8yZpqXmOgRo77WaHEmhYQYGNA6y421PKsKYWEK8aW+cqAphborZDhqfyKrbZEN92CN1X2KbafY2s7Yw==", + "version": "2.0.18", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.18.tgz", + "integrity": "sha512-d9VeXT4SJ7ZeOqGX6R5EM022wpL+eWPooLI+5UpWn2jCT1aosUQEhQP214x33Wkwx3JQMvIm+tIoVOdodFS40g==", "devOptional": true }, "nodemon": { @@ -33671,9 +34540,9 @@ } }, "object-inspect": { - "version": "1.12.2", - "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.2.tgz", - "integrity": "sha512-z+cPxW0QGUp0mcqcsgQyLVRDoXFQbXOwBaqyF7VIgI4TWNQsDHrBpUQslRmIfAoYWdYzs6UlKJtB2XJpTaNSpQ==" + "version": "1.13.2", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.2.tgz", + "integrity": "sha512-IRZSRuzJiynemAXPYtPe5BoI/RESNYR7TYm50MC5Mqbd3Jmw5y790sErYw3V6SryFJD64b74qQQs9wn5Bg/k3g==" }, "object-keys": { "version": "1.1.1", @@ -33950,12 +34819,6 @@ "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", "dev": true }, - "papaparse": { - "version": "5.3.0", - "resolved": "https://registry.npmjs.org/papaparse/-/papaparse-5.3.0.tgz", - "integrity": "sha512-Lb7jN/4bTpiuGPrYy4tkKoUS8sTki8zacB5ke1p5zolhcSE4TlWgrlsxjrDTbG/dFVh07ck7X36hUf/b5V68pg==", - "dev": true - }, "param-case": { "version": "3.0.4", "resolved": "https://registry.npmjs.org/param-case/-/param-case-3.0.4.tgz", @@ -33983,13 +34846,13 @@ } }, "parse-json": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.0.1.tgz", - "integrity": "sha512-ztoZ4/DYeXQq4E21v169sC8qWINGpcosGv9XhTDvg9/hWvx/zrFkc9BiWxR58OJLHGk28j5BL0SDLeV2WmFZlQ==", + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz", + "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==", "requires": { "@babel/code-frame": "^7.0.0", "error-ex": "^1.3.1", - "json-parse-better-errors": "^1.0.1", + "json-parse-even-better-errors": "^2.3.0", "lines-and-columns": "^1.1.6" } }, @@ -34058,20 +34921,25 @@ "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==" }, "path-to-regexp": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", - "integrity": "sha1-32BBeABfUi8V60SQ5yR6G/qmf4w=" + "version": "0.1.10", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.10.tgz", + "integrity": "sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w==" }, "path-type": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz", "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==" }, + "pathe": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/pathe/-/pathe-1.1.2.tgz", + "integrity": "sha512-whLdWMYL2TwI08hn8/ZqAbrVemu0LNaNNJZX73O6qaIdCTfXutsLhMkjdENX0qhsQ9uIimo4/aQOmXkoon2nDQ==", + "dev": true + }, "picocolors": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", - "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", - "devOptional": true + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.1.tgz", + "integrity": "sha512-anP1Z8qwhkbmu7MFP5iTt+wQKXgwzf7zTyGlcdzabySa9vd0Xt392U0rVmz9poOaBj0uHJKyyo9/upk0HrEQew==" }, "picomatch": { "version": "2.3.1", @@ -34118,16 +34986,10 @@ "find-up": "^3.0.0" } }, - "plurals-cldr": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/plurals-cldr/-/plurals-cldr-1.0.4.tgz", - "integrity": "sha512-4nLXqtel7fsCgzi8dvRZvUjfL8SXpP982sKg7b2TgpnR8rDnes06iuQ83trQ/+XdtyMIQkBBbKzX6x97eLfsJQ==", - "dev": true - }, "pofile": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/pofile/-/pofile-1.1.0.tgz", - "integrity": "sha512-6XYcNkXWGiJ2CVXogTP7uJ6ZXQCldYLZc16wgRp8tqRaBTTyIfF+TUT3EQJPXTLAT7OTPpTAoaFdoXKfaTRU1w==", + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/pofile/-/pofile-1.1.4.tgz", + "integrity": "sha512-r6Q21sKsY1AjTVVjOuU02VYKVNQGJNQHjTIvs4dEbeuuYfxgYk/DGD2mqqq4RDaVkwdSq0VEtmQUOPe/wH8X3g==", "dev": true }, "popmotion": { @@ -34273,12 +35135,12 @@ } }, "pseudolocale": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/pseudolocale/-/pseudolocale-1.2.0.tgz", - "integrity": "sha512-k0OQFvIlvpRdzR0dPVrrbWX7eE9EaZ6gpZtTlFSDi1Gf9tMy9wiANCNu7JZ0drcKgUri/39a2mBbH0goiQmrmQ==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/pseudolocale/-/pseudolocale-2.1.0.tgz", + "integrity": "sha512-af5fsrRvVwD+MBasBJvuDChT0KDqT0nEwD9NTgbtHJ16FKomWac9ua0z6YVNB4G9x9IOaiGWym62aby6n4tFMA==", "dev": true, "requires": { - "commander": "*" + "commander": "^10.0.0" } }, "psl": { @@ -34723,9 +35585,9 @@ } }, "regenerator-runtime": { - "version": "0.13.7", - "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.7.tgz", - "integrity": "sha512-a54FxoJDIr27pgf7IgeQGxmqUNYrcV338lf/6gH456HZ/PhX+5BcwHXG9ajESmwe6WRO0tAzRUrRmNONWgkrew==" + "version": "0.14.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.14.1.tgz", + "integrity": "sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==" }, "regenerator-transform": { "version": "0.15.0", @@ -35191,9 +36053,9 @@ "dev": true }, "send": { - "version": "0.18.0", - "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", - "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "version": "0.19.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", + "integrity": "sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==", "requires": { "debug": "2.6.9", "depd": "2.0.0", @@ -35228,9 +36090,9 @@ } }, "serialize-javascript": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.0.tgz", - "integrity": "sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag==", + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz", + "integrity": "sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==", "dev": true, "requires": { "randombytes": "^2.1.0" @@ -35272,14 +36134,51 @@ } }, "serve-static": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.15.0.tgz", - "integrity": "sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g==", + "version": "1.16.0", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.16.0.tgz", + "integrity": "sha512-pDLK8zwl2eKaYrs8mrPZBJua4hMplRWJ1tIFksVC3FtBEBnl8dxgeHtsaMS8DhS9i4fLObaon6ABoc4/hQGdPA==", "requires": { "encodeurl": "~1.0.2", "escape-html": "~1.0.3", "parseurl": "~1.3.3", "send": "0.18.0" + }, + "dependencies": { + "depd": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", + "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==" + }, + "ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==" + }, + "send": { + "version": "0.18.0", + "resolved": "https://registry.npmjs.org/send/-/send-0.18.0.tgz", + "integrity": "sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg==", + "requires": { + "debug": "2.6.9", + "depd": "2.0.0", + "destroy": "1.2.0", + "encodeurl": "~1.0.2", + "escape-html": "~1.0.3", + "etag": "~1.8.1", + "fresh": "0.5.2", + "http-errors": "2.0.0", + "mime": "1.6.0", + "ms": "2.1.3", + "on-finished": "2.4.1", + "range-parser": "~1.2.1", + "statuses": "2.0.1" + } + }, + "statuses": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", + "integrity": "sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ==" + } } }, "set-blocking": { @@ -35288,6 +36187,19 @@ "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", "dev": true }, + "set-function-length": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", + "integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==", + "requires": { + "define-data-property": "^1.1.4", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.2" + } + }, "set-value": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/set-value/-/set-value-2.0.1.tgz", @@ -35364,13 +36276,14 @@ "optional": true }, "side-channel": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", - "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.6.tgz", + "integrity": "sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==", "requires": { - "call-bind": "^1.0.0", - "get-intrinsic": "^1.0.2", - "object-inspect": "^1.9.0" + "call-bind": "^1.0.7", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.4", + "object-inspect": "^1.13.1" } }, "signal-exit": { @@ -36147,34 +37060,28 @@ } }, "terser-webpack-plugin": { - "version": "5.2.5", - "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.2.5.tgz", - "integrity": "sha512-3luOVHku5l0QBeYS8r4CdHYWEGMmIj3H1U64jgkdZzECcSOJAyJ9TjuqcQZvw1Y+4AOBN9SeYJPJmFn2cM4/2g==", + "version": "5.3.10", + "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.3.10.tgz", + "integrity": "sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==", "dev": true, "requires": { - "jest-worker": "^27.0.6", + "@jridgewell/trace-mapping": "^0.3.20", + "jest-worker": "^27.4.5", "schema-utils": "^3.1.1", - "serialize-javascript": "^6.0.0", - "source-map": "^0.6.1", - "terser": "^5.7.2" + "serialize-javascript": "^6.0.1", + "terser": "^5.26.0" }, "dependencies": { "schema-utils": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.1.1.tgz", - "integrity": "sha512-Y5PQxS4ITlC+EahLuXaY86TXfR7Dc5lw294alXOq86JAHCihAIZfqv8nNCWvaEJvaC51uN9hbLGeV0cFBdH+Fw==", + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.3.0.tgz", + "integrity": "sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==", "dev": true, "requires": { "@types/json-schema": "^7.0.8", "ajv": "^6.12.5", "ajv-keywords": "^3.5.2" } - }, - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true } } }, @@ -36352,20 +37259,6 @@ } } }, - "ts-node": { - "version": "9.1.1", - "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-9.1.1.tgz", - "integrity": "sha512-hPlt7ZACERQGf03M253ytLY3dHbGNGrAq9qIHWUY9XHYl1z7wYngSr3OQ5xmui8o2AaxsONxIzjafLUiWBo1Fg==", - "dev": true, - "requires": { - "arg": "^4.1.0", - "create-require": "^1.1.0", - "diff": "^4.0.1", - "make-error": "^1.1.1", - "source-map-support": "^0.5.17", - "yn": "3.1.1" - } - }, "tsconfig-paths": { "version": "3.14.1", "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.14.1.tgz", @@ -36512,17 +37405,16 @@ "set-value": "^2.0.1" } }, - "universalify": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/universalify/-/universalify-1.0.0.tgz", - "integrity": "sha512-rb6X1W158d7pRQBg5gkR8uPaSfiids68LTJQYOtEUhoJUWBdaQHsuT/EUduxXYxcrt4r5PJ4fuHW1MHT6p0qug==", - "dev": true - }, "unpipe": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", "integrity": "sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw=" }, + "unraw": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/unraw/-/unraw-3.0.0.tgz", + "integrity": "sha512-08/DA66UF65OlpUDIQtbJyrqTR0jTAlJ+jsnkQ4jxR7+K5g5YG1APZKQSMCE1vqqmD+2pv6+IdEjmopFatacvg==" + }, "unset-value": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/unset-value/-/unset-value-1.0.0.tgz", @@ -36570,13 +37462,13 @@ } }, "update-browserslist-db": { - "version": "1.0.13", - "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.13.tgz", - "integrity": "sha512-xebP81SNcPuNpPP3uzeW1NYXxI3rxyJzF3pD6sH4jE7o/IX+WtSpwnVU+qIsDPyk0d3hmFQ7mjqc6AtV604hbg==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.1.0.tgz", + "integrity": "sha512-EdRAaAyk2cUE1wOf2DkEhzxqOQvFOoRJFNS6NeyJ01Gp2beMRpBAINjM2iDXE3KCuKhwnvHIQCJm6ThL2Z+HzQ==", "devOptional": true, "requires": { - "escalade": "^3.1.1", - "picocolors": "^1.0.0" + "escalade": "^3.1.2", + "picocolors": "^1.0.1" } }, "uri-js": { @@ -36743,9 +37635,9 @@ } }, "watchpack": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.0.tgz", - "integrity": "sha512-Lcvm7MGST/4fup+ifyKi2hjyIAwcdI4HRgtvTpIUxBRhB+RFtUh8XtDOxUfctVCnhVi+QQj49i91OyvzkJl6cg==", + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.4.2.tgz", + "integrity": "sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw==", "dev": true, "requires": { "glob-to-regexp": "^0.4.1", @@ -36777,41 +37669,40 @@ "dev": true }, "webpack": { - "version": "5.76.2", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.76.2.tgz", - "integrity": "sha512-Th05ggRm23rVzEOlX8y67NkYCHa9nTNcwHPBhdg+lKG+mtiW7XgggjAeeLnADAe7mLjJ6LUNfgHAuRRh+Z6J7w==", + "version": "5.94.0", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.94.0.tgz", + "integrity": "sha512-KcsGn50VT+06JH/iunZJedYGUJS5FGjow8wb9c0v5n1Om8O1g4L6LjtfxwlXIATopoQu+vOXXa7gYisWxCoPyg==", "dev": true, "requires": { - "@types/eslint-scope": "^3.7.3", - "@types/estree": "^0.0.51", - "@webassemblyjs/ast": "1.11.1", - "@webassemblyjs/wasm-edit": "1.11.1", - "@webassemblyjs/wasm-parser": "1.11.1", + "@types/estree": "^1.0.5", + "@webassemblyjs/ast": "^1.12.1", + "@webassemblyjs/wasm-edit": "^1.12.1", + "@webassemblyjs/wasm-parser": "^1.12.1", "acorn": "^8.7.1", - "acorn-import-assertions": "^1.7.6", - "browserslist": "^4.14.5", + "acorn-import-attributes": "^1.9.5", + "browserslist": "^4.21.10", "chrome-trace-event": "^1.0.2", - "enhanced-resolve": "^5.10.0", - "es-module-lexer": "^0.9.0", + "enhanced-resolve": "^5.17.1", + "es-module-lexer": "^1.2.1", "eslint-scope": "5.1.1", "events": "^3.2.0", "glob-to-regexp": "^0.4.1", - "graceful-fs": "^4.2.9", + "graceful-fs": "^4.2.11", "json-parse-even-better-errors": "^2.3.1", "loader-runner": "^4.2.0", "mime-types": "^2.1.27", "neo-async": "^2.6.2", - "schema-utils": "^3.1.0", + "schema-utils": "^3.2.0", "tapable": "^2.1.1", - "terser-webpack-plugin": "^5.1.3", - "watchpack": "^2.4.0", + "terser-webpack-plugin": "^5.3.10", + "watchpack": "^2.4.1", "webpack-sources": "^3.2.3" }, "dependencies": { "schema-utils": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.1.1.tgz", - "integrity": "sha512-Y5PQxS4ITlC+EahLuXaY86TXfR7Dc5lw294alXOq86JAHCihAIZfqv8nNCWvaEJvaC51uN9hbLGeV0cFBdH+Fw==", + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.3.0.tgz", + "integrity": "sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg==", "dev": true, "requires": { "@types/json-schema": "^7.0.8", @@ -37328,12 +38219,6 @@ } } }, - "yn": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", - "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", - "dev": true - }, "yup": { "version": "0.32.11", "resolved": "https://registry.npmjs.org/yup/-/yup-0.32.11.tgz", diff --git a/frontend/package.json b/frontend/package.json index ad574e7761..6454704b7e 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -22,7 +22,7 @@ "@chakra-ui/system": "^2.6.2", "@emotion/react": "^11.9.3", "@emotion/styled": "^11.9.3", - "@lingui/react": "^3.14.0", + "@lingui/react": "^4.11.3", "@visx/axis": "^2.17.0", "@visx/curve": "^3.3.0", "@visx/event": "^2.17.0", @@ -37,11 +37,11 @@ "@visx/shape": "^3.5.0", "@visx/tooltip": "^2.17.0", "@visx/vendor": "^3.5.0", - "body-parser": "^1.19.1", + "body-parser": "^1.20.3", "compression": "^1.7.4", "d3": "^7.8.0", "dotenv": "^16.0.1", - "express": "^4.19.2", + "express": "^4.20.0", "formik": "^2.2.9", "framer-motion": "^4.1.17", "isomorphic-unfetch": "^3.1.0", @@ -66,9 +66,10 @@ "@babel/preset-react": "^7.18.6", "@graphql-tools/mock": "^8.7.0", "@graphql-tools/schema": "^10.0.0", - "@lingui/cli": "^3.14.0", - "@lingui/loader": "^3.14.0", - "@lingui/macro": "^3.14.0", + "@lingui/cli": "^4.11.3", + "@lingui/core": "^4.11.3", + "@lingui/loader": "^4.11.3", + "@lingui/macro": "^4.11.3", "@testing-library/jest-dom": "^5.16.4", "@testing-library/react": "^13.4.0", "@testing-library/react-hooks": "^7.0.2", @@ -99,7 +100,7 @@ "react-test-renderer": "^18.2.0", "source-map-loader": "^4.0.0", "supertest": "^6.2.3", - "webpack": "^5.76.2", + "webpack": "^5.94.0", "webpack-cli": "^4.10.0", "webpack-config-utils": "^2.3.1", "webpack-dev-server": "^4.9.2" diff --git a/frontend/src/admin/AdminDomainCard.js b/frontend/src/admin/AdminDomainCard.js index cac8ca383c..e425d1c1d5 100644 --- a/frontend/src/admin/AdminDomainCard.js +++ b/frontend/src/admin/AdminDomainCard.js @@ -1,9 +1,18 @@ import React from 'react' -import { Trans } from '@lingui/macro' +import { t, Trans } from '@lingui/macro' import { array, bool, string } from 'prop-types' import { Flex, ListItem, Tag, TagLabel, Text } from '@chakra-ui/react' +import { ABTestVariant, ABTestWrapper } from '../app/ABTestWrapper' + +export function AdminDomainCard({ url, tags, assetState, isArchived, rcode, ...rest }) { + const assetStateLabels = { + APPROVED: t`Approved`, + DEPENDENCY: t`Dependency`, + MONITOR_ONLY: t`Monitor Only`, + CANDIDATE: t`Candidate`, + REQUIRES_INVESTIGATION: t`Requires Investigation`, + } -export function AdminDomainCard({ url, tags, isHidden, isArchived, rcode, ...rest }) { return ( @@ -22,18 +31,20 @@ export function AdminDomainCard({ url, tags, isHidden, isArchived, rcode, ...res })} + + + {assetState && ( + + {assetStateLabels[assetState]} + + )} + + {rcode === 'NXDOMAIN' && ( NXDOMAIN )} - {isHidden && ( - - - HIDDEN - - - )} {isArchived && ( @@ -49,7 +60,7 @@ export function AdminDomainCard({ url, tags, isHidden, isArchived, rcode, ...res AdminDomainCard.propTypes = { url: string, tags: array, - isHidden: bool, isArchived: bool, rcode: string, + assetState: string, } diff --git a/frontend/src/admin/AdminDomainModal.js b/frontend/src/admin/AdminDomainModal.js index b38bfe6ce0..058174d694 100644 --- a/frontend/src/admin/AdminDomainModal.js +++ b/frontend/src/admin/AdminDomainModal.js @@ -35,9 +35,10 @@ import { useMutation } from '@apollo/client' import { DomainField } from '../components/fields/DomainField' import { CREATE_DOMAIN, UPDATE_DOMAIN } from '../graphql/mutations' import withSuperAdmin from '../app/withSuperAdmin' +import { ABTestVariant, ABTestWrapper } from '../app/ABTestWrapper' export function AdminDomainModal({ isOpen, onClose, validationSchema, orgId, ...props }) { - const { editingDomainId, editingDomainUrl, tagInputList, orgSlug, archived, hidden, mutation, orgCount } = props + const { editingDomainId, editingDomainUrl, tagInputList, orgSlug, archived, assetState, mutation, orgCount } = props const toast = useToast() const initialFocusRef = useRef() const { i18n } = useLingui() @@ -143,7 +144,6 @@ export function AdminDomainModal({ isOpen, onClose, validationSchema, orgId, ... { en: 'TEST', fr: 'TEST' }, { en: 'WEB', fr: 'WEB' }, { en: 'INACTIVE', fr: 'INACTIF' }, - { en: 'OUTSIDE', fr: 'EXTERIEUR' }, ] const addableTags = (values, helper) => { @@ -194,8 +194,7 @@ export function AdminDomainModal({ isOpen, onClose, validationSchema, orgId, ... // convert initial tags to input type tags: getInitTags(), archiveDomain: archived, - hideDomain: hidden, - outsideComment: null, + assetState: assetState || 'APPROVED', }} initialTouched={{ domainUrl: true, @@ -211,8 +210,7 @@ export function AdminDomainModal({ isOpen, onClose, validationSchema, orgId, ... domain: values.domainUrl.trim(), tags: values.tags, archived: values.archiveDomain, - hidden: values.hideDomain, - outsideComment: values.outsideComment, + assetState: values.assetState, ignoreRua: values.ignoreRua, }, }) @@ -223,8 +221,7 @@ export function AdminDomainModal({ isOpen, onClose, validationSchema, orgId, ... domain: values.domainUrl.trim(), tags: values.tags, archived: values.archiveDomain, - hidden: values.hideDomain, - outsideComment: values.outsideComment, + assetState: values.assetState, }, }) } @@ -265,50 +262,46 @@ export function AdminDomainModal({ isOpen, onClose, validationSchema, orgId, ... )} /> - {values.tags?.find(({ en }) => en === 'OUTSIDE') && ( - - - Reason - - - - - Note: Domains from outside the GC scope may not be scanned right away - - - - )} + + + + + + + Asset State{' '} + + + + + + + + - - - - - - - Hide domain - - { - return [item['filterValue'], item] + if (item['filterCategory'] !== 'TAGS') return [item['filterCategory'], item] + else return [item['filterValue'], item] }), ).values(), ]) resetForm() }} > - {({ handleChange, handleSubmit, errors }) => { + {({ handleChange, handleSubmit, errors, values }) => { return (
@@ -207,6 +206,34 @@ export function AdminDomains({ orgSlug, orgId }) { Filters: + + + + {errors.comparison} + + - {filterTagOptions.map(({ value, text }, idx) => { - return ( - - ) - })} + {values.filterCategory === 'TAGS' ? ( + filterTagOptions.map(({ value, text }, idx) => { + return ( + + ) + }) + ) : ( + <> + + + + + + + + + + + )} {errors.filterValue} + @@ -256,7 +308,7 @@ export function AdminDomains({ orgSlug, orgId }) { )} > - {({ id: domainId, domain, claimTags, hidden, archived, rcode, organizations }, index) => ( + {({ id: domainId, domain, claimTags, archived, rcode, organizations, assetState }, index) => ( <> {index === 0 && } @@ -278,9 +330,9 @@ export function AdminDomains({ orgSlug, orgId }) { px="2" onClick={() => { setModalProps({ - hidden, archived, mutation: 'update', + assetState, tagInputList: claimTags, editingDomainId: domainId, editingDomainUrl: domain, @@ -295,7 +347,7 @@ export function AdminDomains({ orgSlug, orgId }) { { e.preventDefault() // prevents page from refreshing setModalProps({ - hidden: false, archived: false, mutation: 'create', tagInputList: [], @@ -345,7 +396,7 @@ export function AdminDomains({ orgSlug, orgId }) { > Search: - + @@ -360,7 +411,12 @@ export function AdminDomains({ orgSlug, orgId }) { }} /> - @@ -381,15 +437,7 @@ export function AdminDomains({ orgSlug, orgId }) { /> - {filters.map(({ comparison, filterValue }, idx) => { - return ( - - {comparison === 'NOT_EQUAL' && !} - {filterValue} - setFilters(filters.filter((_, i) => i !== idx))} /> - - ) - })} + {adminDomainList} + + + The "Asset State" describes how the domain relates to your organization. These states are used by Tracker to + give you a more accurate summary of your attack surface. + + + + + + + + ) } diff --git a/frontend/src/admin/__tests__/AdminDomainCard.test.js b/frontend/src/admin/__tests__/AdminDomainCard.test.js index 42d1eeb1ae..49f3187ca2 100644 --- a/frontend/src/admin/__tests__/AdminDomainCard.test.js +++ b/frontend/src/admin/__tests__/AdminDomainCard.test.js @@ -8,6 +8,8 @@ import { setupI18n } from '@lingui/core' import { AdminDomainCard } from '../AdminDomainCard' import { MockedProvider } from '@apollo/client/testing' import { IS_USER_SUPER_ADMIN } from '../../graphql/queries' +import { UserVarProvider } from '../../utilities/userState' +import { makeVar } from '@apollo/client' const i18n = setupI18n({ locale: 'en', @@ -36,15 +38,24 @@ describe('', () => { it('represents a domain', async () => { const { getByText } = render( - - - - - - - - - + + + + + + + + + + + , ) diff --git a/frontend/src/admin/__tests__/AdminDomains.test.js b/frontend/src/admin/__tests__/AdminDomains.test.js index bfbdc9cc09..5a927aa949 100644 --- a/frontend/src/admin/__tests__/AdminDomains.test.js +++ b/frontend/src/admin/__tests__/AdminDomains.test.js @@ -136,9 +136,7 @@ describe('', () => { orgId: 'gwdsfgvwsdgfvswefgdv', domain: 'test-domain.gc.ca', tags: [{ en: 'NEW', fr: 'NOUVEAU' }], - hidden: false, archived: false, - outsideComment: null, }, }, result: { @@ -228,9 +226,8 @@ describe('', () => { orgId: 'testid=', domain: 'test-domain.gc.ca', tags: [{ en: 'NEW', fr: 'NOUVEAU' }], - hidden: false, archived: false, - outsideComment: null, + assetState: 'APPROVED', }, }, result: { @@ -324,9 +321,9 @@ describe('', () => { orgId: rawOrgDomainListData.findOrganizationBySlug.id, domain: 'test.domain.gc.ca', tags: [{ en: 'NEW', fr: 'NOUVEAU' }], - hidden: false, + archived: false, - outsideComment: null, + assetState: 'APPROVED', }, }, result: { @@ -343,13 +340,14 @@ describe('', () => { }, ] - const { getByText, getByPlaceholderText, findByText, queryByText } = render( + const { getByText, getByPlaceholderText, findByText, queryByText, findByRole } = render( @@ -378,6 +376,16 @@ describe('', () => { userEvent.click(addDomainButton) + await waitFor(() => expect(getByText(/Add Domain Details/i)).toBeInTheDocument()) + + const assetStateSelect = await findByRole('combobox', { name: /Asset State/ }) + + fireEvent.change(assetStateSelect, { + target: { + value: 'APPROVED', + }, + }) + const confirmBtn = getByText(/Confirm/) fireEvent.click(confirmBtn) @@ -466,7 +474,7 @@ describe('', () => { }) describe('editing a domain', () => { - it.skip('successfully edits domain URL', async () => { + it('successfully edits domain URL', async () => { const mocks = [ { request: { @@ -489,9 +497,9 @@ describe('', () => { orgId: 'testid=', domain: 'test.domain.ca', tags: [], - hidden: false, + archived: false, - outsideComment: null, + assetState: 'MONITOR_ONLY', }, }, result: { @@ -508,13 +516,14 @@ describe('', () => { }, ] - const { getByText, findByTestId, getByLabelText, queryByText } = render( + const { getByText, findByTestId, getByLabelText, queryByText, findByRole } = render( @@ -544,6 +553,14 @@ describe('', () => { }, }) + const assetStateSelect = await findByRole('combobox', { name: /Asset State/ }) + + fireEvent.change(assetStateSelect, { + target: { + value: 'MONITOR_ONLY', + }, + }) + const confirm = getByText('Confirm') fireEvent.click(confirm) diff --git a/frontend/src/app/App.js b/frontend/src/app/App.js index 9aad3aaf4d..f109c3028a 100644 --- a/frontend/src/app/App.js +++ b/frontend/src/app/App.js @@ -1,9 +1,8 @@ import React, { Suspense } from 'react' import { Switch, Link as RouteLink, Redirect, useLocation } from 'react-router-dom' -import { AlertDescription, AlertTitle, Box, Code, CSSReset, Flex, Link, Text } from '@chakra-ui/react' +import { AlertDescription, AlertTitle, Box, Code, CSSReset, Flex, Link, Skeleton, Text } from '@chakra-ui/react' import { t, Trans } from '@lingui/macro' import { ErrorBoundary } from 'react-error-boundary' -import { useQuery } from '@apollo/client' import { Main } from './Main' import { TopBanner } from './TopBanner' @@ -24,6 +23,7 @@ import { NotificationBanner } from './NotificationBanner' import { IS_LOGIN_REQUIRED } from '../graphql/queries' import { useLingui } from '@lingui/react' import { ScrollToAnchor } from './ScrollToAnchor' +import { bool } from 'prop-types' const GuidancePage = lazyWithRetry(() => import('../guidance/GuidancePage')) const PageNotFound = lazyWithRetry(() => import('./PageNotFound')) @@ -46,15 +46,12 @@ const ContactUsPage = lazyWithRetry(() => import('./ContactUsPage')) const ReadGuidancePage = lazyWithRetry(() => import('./ReadGuidancePage')) const MyTrackerPage = lazyWithRetry(() => import('../user/MyTrackerPage')) -export function App() { +export function App({ initialLoading, isLoginRequired }) { // Hooks to be used with this functional component const { currentUser, isLoggedIn, isEmailValidated, currentTFAMethod, hasAffiliation } = useUserVar() const { i18n } = useLingui() - const { data, loading } = useQuery(IS_LOGIN_REQUIRED, {}) const location = useLocation() - if (loading) return - const notificationBanner = () => { if (isLoggedIn()) { if (isEmailValidated()) { @@ -114,47 +111,60 @@ export function App() { Skip to main content - + Home - {((isLoggedIn() && isEmailValidated()) || !data?.loginRequired) && ( - <> - - Organizations - - - Domains - - - )} - - {isLoggedIn() && isEmailValidated() && currentTFAMethod() !== 'NONE' && ( - - DMARC Summaries - - )} - - {isLoggedIn() && ( + {initialLoading ? ( <> - - myTracker - - - - Account Settings - + + LoadingState + + + LoadingState + - )} - - {isLoggedIn() && isEmailValidated() && currentTFAMethod() !== 'NONE' && ( + ) : ( <> - - Admin Profile - + {((isLoggedIn() && isEmailValidated()) || !isLoginRequired) && ( + <> + + Organizations + + + Domains + + + )} + + {isLoggedIn() && isEmailValidated() && currentTFAMethod() !== 'NONE' && ( + + DMARC Summaries + + )} + + {isLoggedIn() && ( + <> + + myTracker + + + + Account Settings + + + )} + + {isLoggedIn() && isEmailValidated() && currentTFAMethod() !== 'NONE' && ( + <> + + Admin Profile + + + )} )} @@ -179,165 +189,169 @@ export function App() {
- }> - - - - - - - - - - { - return isLoggedIn() ? ( + {initialLoading ? ( + + ) : ( + }> + + + + + + + + + + { + return isLoggedIn() ? ( + + ) : ( + + ) + }} + /> + + + + + + + + + + + + + + + {() => ( + + + + )} + + + + {() => ( + + + + )} + + + + {isLoggedIn() && isEmailValidated() && currentTFAMethod() !== 'NONE' ? ( + + ) : ( + + )} + + + + {() => ( + + + + )} + + + + {() => ( + + + + )} + + + + {() => ( + + + + )} + + + + {() => ( + + + + )} + + + + {isLoggedIn() ? ( + + ) : ( + )} + + + + {isLoggedIn() ? ( + + ) : ( + + )} + + + + {() => } + + + + {isLoggedIn() && isEmailValidated() && currentTFAMethod() !== 'NONE' ? ( + ) : ( - - ) - }} - /> - - - - - - - - - - - - - - - {() => ( - - - - )} - - - - {() => ( - - - - )} - - - - {isLoggedIn() && isEmailValidated() && currentTFAMethod() !== 'NONE' ? ( - - ) : ( - - )} - - - - {() => ( - - - - )} - - - - {() => ( - - - - )} - - - - {() => ( - - - - )} - - - - {() => ( - - - - )} - - - - {isLoggedIn() ? ( - - ) : ( - - )} - - - - {isLoggedIn() ? ( - - ) : ( - - )} - - - - {() => } - - - - {isLoggedIn() && isEmailValidated() && currentTFAMethod() !== 'NONE' ? ( - - ) : ( - - )} - - - - - + + )} + + + + + + )}
@@ -369,3 +383,8 @@ export function App() {
) } + +App.propTypes = { + initialLoading: bool, + isLoginRequired: bool, +} diff --git a/frontend/src/app/ReadGuidancePage.js b/frontend/src/app/ReadGuidancePage.js index 2d12d1c8f7..5b0cbe4029 100644 --- a/frontend/src/app/ReadGuidancePage.js +++ b/frontend/src/app/ReadGuidancePage.js @@ -110,7 +110,7 @@ export default function ReadGuidancePage() { Domains are only to be removed from your list when 1) they no longer exist, meaning they are deleted - from the DNS returning an error code of NX DOMAIN (domain name does not exist); or 2) if you have + from the DNS returning an error code of NXDOMAIN (domain name does not exist); or 2) if you have identified that they do not belong to your organization. diff --git a/frontend/src/app/TopBanner.js b/frontend/src/app/TopBanner.js index fc6fdf460d..e189360779 100644 --- a/frontend/src/app/TopBanner.js +++ b/frontend/src/app/TopBanner.js @@ -1,6 +1,6 @@ import React from 'react' import { t, Trans } from '@lingui/macro' -import { Box, Button, Flex, useToast, Image, Link } from '@chakra-ui/react' +import { Box, Button, Flex, useToast, Image, Link, Skeleton } from '@chakra-ui/react' import { Link as RouteLink } from 'react-router-dom' import { useMutation } from '@apollo/client' @@ -17,8 +17,9 @@ import { SIGN_OUT } from '../graphql/mutations' import { PhaseBanner } from './PhaseBanner' import { useLingui } from '@lingui/react' import { ABTestWrapper, ABTestVariant } from './ABTestWrapper' +import { bool } from 'prop-types' -export const TopBanner = (props) => { +export const TopBanner = ({ initialLoading, ...props }) => { const { isLoggedIn, logout } = useUserVar() const toast = useToast() const { i18n } = useLingui() @@ -98,7 +99,20 @@ export const TopBanner = (props) => { - {isLoggedIn() ? ( + {initialLoading ? ( + <> + + + + + + + + ) : isLoggedIn() ? ( diff --git a/frontend/src/components/InfoPanel.js b/frontend/src/components/InfoPanel.js index 82793ff3ca..ef70cbc7d0 100644 --- a/frontend/src/components/InfoPanel.js +++ b/frontend/src/components/InfoPanel.js @@ -1,6 +1,6 @@ import React from 'react' import { any, bool, func, string } from 'prop-types' -import { Trans } from '@lingui/macro' +import { t, Trans } from '@lingui/macro' import { Box, Drawer, @@ -16,16 +16,14 @@ import { } from '@chakra-ui/react' import { QuestionOutlineIcon } from '@chakra-ui/icons' -export function InfoPanel({ isOpen, onToggle, children }) { +export function InfoPanel({ title = t`Glossary`, isOpen, onToggle, children, ...props }) { const btnRef = React.useRef() return ( - + - + - - Glossary - + {title} {children} @@ -63,6 +61,7 @@ export function InfoButton({ onToggle, ...props }) { } InfoPanel.propTypes = { + title: string, isOpen: bool, onToggle: func, children: any, diff --git a/frontend/src/components/LoadingMessage.js b/frontend/src/components/LoadingMessage.js index 2d6f664450..f833faed38 100644 --- a/frontend/src/components/LoadingMessage.js +++ b/frontend/src/components/LoadingMessage.js @@ -3,17 +3,11 @@ import { Spinner, Stack, Text } from '@chakra-ui/react' import { any } from 'prop-types' import { Trans } from '@lingui/macro' -export function LoadingMessage({ children }) { +export function LoadingMessage({ children, ...rest }) { return ( - + - + Loading {children}... diff --git a/frontend/src/components/MonthSelect.js b/frontend/src/components/MonthSelect.js index ca2a7d9801..5465b80b60 100644 --- a/frontend/src/components/MonthSelect.js +++ b/frontend/src/components/MonthSelect.js @@ -56,11 +56,8 @@ export function MonthSelect({ selectedValue, handleChange, ...props }) { }, ] const options = [ - , ] @@ -68,12 +65,8 @@ export function MonthSelect({ selectedValue, handleChange, ...props }) { for (let i = currentDate.getMonth(), j = 13; j > 0; i--, j--) { // handle previous year if (i < 0) { - const value = `${months[months.length + i].value.toUpperCase()}, ${ - currentDate.getFullYear() - 1 - }` - const translatedValue = `${months[ - months.length + i - ].text.toUpperCase()}, ${currentDate.getFullYear() - 1}` + const value = `${months[months.length + i].value.toUpperCase()}, ${currentDate.getFullYear() - 1}` + const translatedValue = `${months[months.length + i].text.toUpperCase()}, ${currentDate.getFullYear() - 1}` options.push(
+ {searchTip && ( + + {searchTip} + + )} { toast({ title: t`An error occurred while favouriting a domain.`, @@ -66,7 +68,7 @@ export function DomainCard({ }, }) - const [unfavouriteDomain, { _l, _e }] = useMutation(UNFAVOURITE_DOMAIN, { + const [unfavouriteDomain] = useMutation(UNFAVOURITE_DOMAIN, { refetchQueries: ['FindMyTracker'], awaitRefetchQueries: true, @@ -104,6 +106,14 @@ export function DomainCard({ bg: 'gray.100', } + const assetStateLabels = { + APPROVED: t`Approved`, + DEPENDENCY: t`Dependency`, + MONITOR_ONLY: t`Monitor Only`, + CANDIDATE: t`Candidate`, + REQUIRES_INVESTIGATION: t`Requires Investigation`, + } + return ( )} + {hasEntrustCertificate && ( + + + + Entrust Certificate + + + + )} {webScanPending && ( Scan Pending )} + + + {assetState && ( + + {assetStateLabels[assetState]} + + )} + + {url} @@ -165,13 +193,6 @@ export function DomainCard({
) })} - {isHidden && ( - - - HIDDEN - - - )} {isArchived && ( @@ -179,6 +200,24 @@ export function DomainCard({ )} + + + {userHasPermission && cveDetected && ( + + + Vulnerability + + + )} + +
@@ -275,10 +314,12 @@ DomainCard.propTypes = { status: object, hasDMARCReport: bool, tags: array, - isHidden: bool, isArchived: bool, blocked: bool, wildcardSibling: bool, webScanPending: bool, + hasEntrustCertificate: bool, userHasPermission: bool, + assetState: string, + cveDetected: bool, } diff --git a/frontend/src/domains/DomainListFilters.js b/frontend/src/domains/DomainListFilters.js index b2469cd996..7936f5a3e9 100644 --- a/frontend/src/domains/DomainListFilters.js +++ b/frontend/src/domains/DomainListFilters.js @@ -4,14 +4,49 @@ import { Formik } from 'formik' import React from 'react' import { getRequirement, schemaToValidation } from '../utilities/fieldRequirements' import { array, func } from 'prop-types' +import { ABTestVariant, ABTestWrapper } from '../app/ABTestWrapper' -export function DomainListFilters({ filters, setFilters, statusOptions, filterTagOptions }) { +export function DomainListFilters({ filters, setFilters, statusOptions, filterTagOptions, assetStateOptions = [] }) { const validationSchema = schemaToValidation({ filterCategory: getRequirement('field'), comparison: getRequirement('field'), filterValue: getRequirement('field'), }) + const filterValues = (values) => { + if (values.filterCategory === 'TAGS') { + return filterTagOptions.map(({ value, text }, idx) => { + return ( + + ) + }) + } else if (values.filterCategory === 'ASSET_STATE') { + return assetStateOptions.map(({ value, text }, idx) => { + return ( + + ) + }) + } else { + return ( + <> + + + + + ) + } + } + return ( { - if ( - (values.filterCategory === 'TAGS' && e.target.value !== 'TAGS') || - (values.filterCategory !== 'TAGS' && e.target.value === 'TAGS') - ) { - values.filterValue = '' - } + if (values.filterCategory !== e.target.value) values.filterValue = '' handleChange(e) }} > @@ -65,6 +95,11 @@ export function DomainListFilters({ filters, setFilters, statusOptions, filterTa + {assetStateOptions.length > 0 && ( + + )} {errors.filterCategory} @@ -89,29 +124,16 @@ export function DomainListFilters({ filters, setFilters, statusOptions, filterTa {errors.filterValue} @@ -134,4 +156,5 @@ DomainListFilters.propTypes = { setFilters: func, statusOptions: array, filterTagOptions: array, + assetStateOptions: array, } diff --git a/frontend/src/domains/DomainsPage.js b/frontend/src/domains/DomainsPage.js index 74131587f9..1395be9aa5 100644 --- a/frontend/src/domains/DomainsPage.js +++ b/frontend/src/domains/DomainsPage.js @@ -1,6 +1,17 @@ import React, { useCallback, useState } from 'react' import { t, Trans } from '@lingui/macro' -import { Box, Divider, Flex, Heading, Text, useDisclosure, useToast } from '@chakra-ui/react' +import { + Box, + Code, + Divider, + Flex, + Heading, + ListItem, + Text, + UnorderedList, + useDisclosure, + useToast, +} from '@chakra-ui/react' import { ErrorBoundary } from 'react-error-boundary' import { DomainCard } from './DomainCard' @@ -12,7 +23,7 @@ import { ErrorFallbackMessage } from '../components/ErrorFallbackMessage' import { LoadingMessage } from '../components/LoadingMessage' import { useDebouncedFunction } from '../utilities/useDebouncedFunction' import { usePaginatedCollection } from '../utilities/usePaginatedCollection' -import { PAGINATED_DOMAINS as FORWARD, GET_ALL_ORGANIZATION_DOMAINS_STATUSES_CSV } from '../graphql/queries' +import { GET_ALL_ORGANIZATION_DOMAINS_STATUSES_CSV, PAGINATED_DOMAINS as FORWARD } from '../graphql/queries' import { SearchBox } from '../components/SearchBox' import { useLazyQuery } from '@apollo/client' import { ExportButton } from '../components/ExportButton' @@ -20,7 +31,6 @@ import { AffiliationFilterSwitch } from '../components/AffiliationFilterSwitch' import { useUserVar } from '../utilities/userState' import { DomainListFilters } from './DomainListFilters' import { FilterList } from './FilterList' -import { ABTestVariant, ABTestWrapper } from '../app/ABTestWrapper' import withSuperAdmin from '../app/withSuperAdmin' export default function DomainsPage() { @@ -93,6 +103,7 @@ export default function DomainsPage() { { value: `BLOCKED`, text: t`Blocked` }, { value: `WILDCARD_SIBLING`, text: t`Wildcard` }, { value: `SCAN_PENDING`, text: t`Scan Pending` }, + { value: `HAS_ENTRUST_CERTIFICATE`, text: t`Entrust` }, ] const StatusExportButton = withSuperAdmin(() => { @@ -136,16 +147,12 @@ export default function DomainsPage() { ) : ( - - - - - + ( @@ -166,7 +173,9 @@ export default function DomainsPage() { blocked, wildcardSibling, webScanPending, + hasEntrustCertificate, userHasPermission, + cveDetected, }, index, ) => ( @@ -181,7 +190,9 @@ export default function DomainsPage() { blocked={blocked} wildcardSibling={wildcardSibling} webScanPending={webScanPending} + hasEntrustCertificate={hasEntrustCertificate} userHasPermission={userHasPermission} + cveDetected={cveDetected} mb="3" /> @@ -229,6 +240,8 @@ export default function DomainsPage() { info={t`Tag used to show domains which may be from a wildcard subdomain (a wildcard resolver exists as a sibling).`} /> + + @@ -248,6 +261,7 @@ export default function DomainsPage() { orderByOptions={[{ value: 'DOMAIN', text: t`Domain` }, ...orderByOptions]} placeholder={t`Search for a domain`} onToggle={onToggle} + searchTip={domainSearchTip} /> {isLoggedIn() && ( @@ -256,11 +270,7 @@ export default function DomainsPage() { - - - - - + )} @@ -282,3 +292,47 @@ export default function DomainsPage() { ) } + +export const domainSearchTip = ( + + + + Search Tip: Wildcard % + + + + Use % to broaden your search: + + + + + Start with % + + : Search{' '} + + %example.gc.ca + {' '} + to find subdomains like "sub.example.gc.ca." + + + + End with % + + : Search{' '} + + example%{' '} + + to find domains like "example.gc.ca" or "example.canada.ca." + + + Use both: Search{' '} + + %example%{' '} + + to find anything containing "example", like + "sub.example.gc.ca" or "example.canada.ca." + + + This helps you quickly locate related domains and subdomains. + +) diff --git a/frontend/src/domains/FilterList.js b/frontend/src/domains/FilterList.js index 1716d2b89d..59536530c4 100644 --- a/frontend/src/domains/FilterList.js +++ b/frontend/src/domains/FilterList.js @@ -6,50 +6,75 @@ import { t } from '@lingui/macro' import { array, func } from 'prop-types' export function FilterList({ filters, setFilters }) { + const statuses = { + HTTPS_STATUS: `HTTPS`, + HSTS_STATUS: `HSTS`, + CERTIFICATES_STATUS: `Certificates`, + CIPHERS_STATUS: `Ciphers`, + CURVES_STATUS: t`Curves`, + PROTOCOLS_STATUS: t`Protocols`, + SPF_STATUS: `SPF`, + DKIM_STATUS: `DKIM`, + DMARC_STATUS: `DMARC`, + } + + const assetStateLabels = { + APPROVED: t`Approved`, + DEPENDENCY: t`Dependency`, + MONITOR_ONLY: t`Monitor Only`, + CANDIDATE: t`Candidate`, + REQUIRES_INVESTIGATION: t`Requires Investigation`, + } + + const displayTagFilterName = (filterValue) => { + switch (filterValue) { + case 'CVE_DETECTED': + return t`Vulnerability` + case 'HAS_ENTRUST_CERTIFICATE': + return t`Entrust Certificate` + default: + return filterValue + } + } + + const tagBgColour = (filterValue) => { + switch (filterValue) { + case 'PASS': + return 'strongMuted' + case 'FAIL': + return 'weakMuted' + case 'INFO': + return 'infoMuted' + default: + return 'gray.100' + } + } + + const displayTag = (filterCategory, filterValue) => { + if (filterCategory === 'TAGS') { + return {displayTagFilterName(filterValue)} + } else if (filterCategory === 'ASSET_STATE') { + return {assetStateLabels[filterValue]} + } else { + return ( + <> + {statuses[filterCategory]} + + + ) + } + } + return ( <> {filters.map(({ filterCategory, comparison, filterValue }, idx) => { - const statuses = { - HTTPS_STATUS: `HTTPS`, - HSTS_STATUS: `HSTS`, - CERTIFICATES_STATUS: `Certificates`, - CIPHERS_STATUS: `Ciphers`, - CURVES_STATUS: t`Curves`, - PROTOCOLS_STATUS: t`Protocols`, - SPF_STATUS: `SPF`, - DKIM_STATUS: `DKIM`, - DMARC_STATUS: `DMARC`, - } return ( - + {comparison === 'NOT_EQUAL' && !} - {filterCategory === 'TAGS' ? ( - {filterValue} - ) : ( - <> - {statuses[filterCategory]} - - - )} - + {displayTag(filterCategory, filterValue)} setFilters(filters.filter((_, i) => i !== idx))} /> ) diff --git a/frontend/src/fixtures/dmarcGuidancePageData.js b/frontend/src/fixtures/dmarcGuidancePageData.js index 3d5ef43bee..262e2efb11 100644 --- a/frontend/src/fixtures/dmarcGuidancePageData.js +++ b/frontend/src/fixtures/dmarcGuidancePageData.js @@ -4,6 +4,7 @@ export const rawDmarcGuidancePageData = { domain: 'amie.info', lastRan: '2019-01-03 20:06:12.437Z', rcode: 'Hello World', + userHasPermission: true, status: { dkim: 'INFO', dmarc: 'INFO', diff --git a/frontend/src/fixtures/orgDomainListData.js b/frontend/src/fixtures/orgDomainListData.js index 6968a7f47a..bfea568511 100644 --- a/frontend/src/fixtures/orgDomainListData.js +++ b/frontend/src/fixtures/orgDomainListData.js @@ -11,7 +11,7 @@ export const rawOrgDomainListData = { lastRan: null, claimTags: [], archived: false, - hidden: false, + assetState: 'APPROVED', rcode: 'NOERROR', organizations: { totalCount: 1, @@ -27,7 +27,7 @@ export const rawOrgDomainListData = { lastRan: '2020-12-06 17:51:25.113689', claimTags: [], archived: false, - hidden: false, + assetState: 'APPROVED', rcode: 'NOERROR', organizations: { totalCount: 1, @@ -43,7 +43,7 @@ export const rawOrgDomainListData = { lastRan: '2020-12-06 17:51:25.113689', claimTags: [], archived: false, - hidden: false, + assetState: 'APPROVED', rcode: 'NOERROR', organizations: { totalCount: 1, diff --git a/frontend/src/graphql/mutations.js b/frontend/src/graphql/mutations.js index 2cfff120bb..db047bde15 100644 --- a/frontend/src/graphql/mutations.js +++ b/frontend/src/graphql/mutations.js @@ -183,26 +183,16 @@ export const CREATE_DOMAIN = gql` $domain: DomainScalar! $tags: [InputTag] $archived: Boolean - $hidden: Boolean - $outsideComment: OutsideDomainCommentEnum + $assetState: AssetStateEnums! ) { - createDomain( - input: { - orgId: $orgId - domain: $domain - tags: $tags - archived: $archived - hidden: $hidden - outsideComment: $outsideComment - } - ) { + createDomain(input: { orgId: $orgId, domain: $domain, tags: $tags, archived: $archived, assetState: $assetState }) { result { ... on Domain { id domain lastRan claimTags - hidden + assetState archived rcode } @@ -276,8 +266,7 @@ export const UPDATE_DOMAIN = gql` $domain: DomainScalar $tags: [InputTag] $archived: Boolean - $hidden: Boolean - $outsideComment: OutsideDomainCommentEnum + $assetState: AssetStateEnums $ignoreRua: Boolean ) { updateDomain( @@ -287,8 +276,7 @@ export const UPDATE_DOMAIN = gql` domain: $domain tags: $tags archived: $archived - hidden: $hidden - outsideComment: $outsideComment + assetState: $assetState ignoreRua: $ignoreRua } ) { @@ -298,7 +286,7 @@ export const UPDATE_DOMAIN = gql` domain lastRan claimTags - hidden + assetState archived rcode ignoreRua diff --git a/frontend/src/graphql/queries.js b/frontend/src/graphql/queries.js index 728403d656..9f5b12a1ea 100644 --- a/frontend/src/graphql/queries.js +++ b/frontend/src/graphql/queries.js @@ -190,7 +190,7 @@ export const PAGINATED_ORG_DOMAINS_ADMIN_PAGE = gql` domain lastRan claimTags - hidden + assetState archived ignoreRua rcode @@ -214,6 +214,7 @@ export const PAGINATED_ORG_DOMAINS_ADMIN_PAGE = gql` export const DOMAIN_GUIDANCE_PAGE = gql` query DomainGuidancePage($domain: DomainScalar!) { findDomainByDomain(domain: $domain) { + id domain lastRan rcode @@ -434,6 +435,7 @@ export const DOMAIN_GUIDANCE_PAGE = gql` verifiedChainHasSha1Signature verifiedChainHasLegacySymantecAnchor passedValidation + hasEntrustCertificate certificateChain { notValidBefore notValidAfter @@ -515,6 +517,15 @@ export const DOMAIN_GUIDANCE_PAGE = gql` } } } + } + } + ${Status.fragments.requiredFields} + ${Guidance.fragments.requiredFields} +` + +export const GUIDANCE_ADDITIONAL_FINDINGS = gql` + query ($domain: DomainScalar!) { + findDomainByDomain(domain: $domain) { additionalFindings { timestamp headers @@ -536,6 +547,9 @@ export const DOMAIN_GUIDANCE_PAGE = gql` webComponentVersion webComponentFirstSeen webComponentLastSeen + webComponentCves { + cve + } } vulnerabilities { critical { @@ -558,8 +572,6 @@ export const DOMAIN_GUIDANCE_PAGE = gql` } } } - ${Status.fragments.requiredFields} - ${Guidance.fragments.requiredFields} ` export const ORG_DETAILS_PAGE = gql` @@ -667,13 +679,15 @@ export const PAGINATED_ORG_DOMAINS = gql` } hasDMARCReport claimTags - hidden + assetState archived rcode blocked wildcardSibling webScanPending userHasPermission + hasEntrustCertificate + cveDetected } } } @@ -742,6 +756,8 @@ export const PAGINATED_DOMAINS = gql` archived hasDMARCReport userHasPermission + hasEntrustCertificate + cveDetected __typename } __typename diff --git a/frontend/src/guidance/AdditionalFindings.js b/frontend/src/guidance/AdditionalFindings.js index 41d20f62f6..9cbfe14cfa 100644 --- a/frontend/src/guidance/AdditionalFindings.js +++ b/frontend/src/guidance/AdditionalFindings.js @@ -1,4 +1,4 @@ -import React from 'react' +import React, { useState } from 'react' import { Accordion, AccordionItem, @@ -18,21 +18,55 @@ import { ModalFooter, ModalBody, ModalCloseButton, - Tag, Link, SimpleGrid, } from '@chakra-ui/react' import { ExternalLinkIcon } from '@chakra-ui/icons' import { Trans, t } from '@lingui/macro' -import { any, object } from 'prop-types' +import { any, string } from 'prop-types' import { useLingui } from '@lingui/react' +import { useQuery } from '@apollo/client' +import { GUIDANCE_ADDITIONAL_FINDINGS } from '../graphql/queries' +import { LoadingMessage } from '../components/LoadingMessage' +import { ErrorFallbackMessage } from '../components/ErrorFallbackMessage' -export function AdditionalFindings({ data }) { +export function AdditionalFindings({ domain }) { + const { i18n } = useLingui() const vulnerabilitySeverities = { critical: t`Critical`, high: t`High`, medium: t`Medium`, low: t`Low` } + const cveSeverityOnHover = { critical: 'red.100', high: 'orange.100', medium: 'yellow.50', low: 'gray.100' } + const [activeCve, setActiveCve] = useState('') const { isOpen, onOpen, onClose } = useDisclosure() + const { isOpen: cveIsOpen, onOpen: cveOnOpen, onClose: cveOnClose } = useDisclosure() + const formatTimestamp = (datetime) => new Date(datetime).toLocaleDateString() - const { timestamp, headers, webComponents, vulnerabilities, ports } = data + const { data, loading, error } = useQuery(GUIDANCE_ADDITIONAL_FINDINGS, { + variables: { domain }, + }) + + if (loading) { + return ( + + Additional Findings + + ) + } + + if (error) { + return + } + + if (!data.findDomainByDomain.additionalFindings) { + return ( + + + No additional findings available at this time. + + + ) + } + + const { timestamp, headers, webComponents, vulnerabilities, ports } = data.findDomainByDomain.additionalFindings const frameworkComponents = webComponents.filter(({ webComponentCategory }) => webComponentCategory === 'Framework') const ddosProtectionComponent = webComponents.find( ({ webComponentCategory }) => webComponentCategory === 'DDOS Protection', @@ -53,6 +87,67 @@ export function AdditionalFindings({ data }) { What are these additional findings? + + + + Vulnerabilities + + + + + + Improving GC Cyber Security Health SPIN + + {Object.keys(vulnerabilitySeverities).map((severity) => { + return ( + vulnerabilities[severity].length > 0 && ( + + + {vulnerabilitySeverities[severity]} + + + {vulnerabilities[severity].map(({ cve }) => { + return ( + + ) + })} + + + ) + ) + })} + + + @@ -168,8 +263,10 @@ export function AdditionalFindings({ data }) { - 3.1.3 Use GC-approved content delivery networks (CDN) that cache websites and protects access to the - origin server. + + 3.1.3 Use GC-approved content delivery networks (CDN) that cache websites and protects access to the + origin server. + {cdnComponent ? ( @@ -199,12 +296,18 @@ export function AdditionalFindings({ data }) { {sortedPorts.map(({ port, lastPortState, portStateFirstSeen, portStateLastSeen }) => { + const lastPortStateTranslated = + lastPortState.toUpperCase() === 'OPEN' + ? t`Open` + : lastPortState.toUpperCase() === 'FILTERED' + ? t`Filtered` + : lastPortState return ( {port} - State: {lastPortState} + State: {lastPortStateTranslated} First Seen: {formatTimestamp(portStateFirstSeen)} @@ -219,40 +322,30 @@ export function AdditionalFindings({ data }) { })} - - - - - Vulnerabilities - - - - - {Object.keys(vulnerabilitySeverities).map((severity) => { - return ( - - - {vulnerabilitySeverities[severity]} - - - {vulnerabilities[severity].map(({ cve }) => { - return ( - - - {cve} - - - ) - })} - - - ) - })} - - + + + + {activeCve?.cve} + + + Affected Components: + {activeCve?.affectedWebComps?.map(({ webComponentName, webComponentCategory, webComponentVersion }) => ( + + {webComponentName} {webComponentCategory} {webComponentVersion} + + ))} + + + + More info + + + + + @@ -297,7 +390,7 @@ function WebRequirementsLink({ children }) { } AdditionalFindings.propTypes = { - data: object.isRequired, + domain: string.isRequired, } WebRequirementsLink.propTypes = { diff --git a/frontend/src/guidance/EmailGuidance.js b/frontend/src/guidance/EmailGuidance.js index 670b3ba740..8aafc2fe02 100644 --- a/frontend/src/guidance/EmailGuidance.js +++ b/frontend/src/guidance/EmailGuidance.js @@ -153,7 +153,9 @@ export function EmailGuidance({ dnsResults, dmarcPhase, status, mxRecordDiff }) return ( - Last Scanned: {formatTimestamp(timestamp)} + + Last Scanned: {formatTimestamp(timestamp)} + {emailSummary} @@ -362,10 +364,14 @@ export function EmailGuidance({ dnsResults, dmarcPhase, status, mxRecordDiff }) Warnings: {mxRecords.warnings.map((warning, idx) => { + const warningTranslated = + warning.toLowerCase() === 'no mx records found. is the domain parked?' + ? t`No MX records found. Is the domain parked?` + : warning return ( - {idx + 1}. {warning} + {idx + 1}. {warningTranslated} ) diff --git a/frontend/src/guidance/GuidancePage.js b/frontend/src/guidance/GuidancePage.js index 065ef1846b..7358d03e7d 100644 --- a/frontend/src/guidance/GuidancePage.js +++ b/frontend/src/guidance/GuidancePage.js @@ -1,5 +1,5 @@ -import React, { useState } from 'react' -import { ArrowLeftIcon } from '@chakra-ui/icons' +import React, { useEffect, useState } from 'react' +import { ArrowLeftIcon, StarIcon } from '@chakra-ui/icons' import { Badge, @@ -16,6 +16,7 @@ import { Tabs, Text, useDisclosure, + useToast, } from '@chakra-ui/react' import { ScanDomainButton } from '../domains/ScanDomainButton' @@ -23,8 +24,9 @@ import { Link as RouteLink, useHistory, useLocation, useParams } from 'react-rou import { WebGuidance } from './WebGuidance' import { EmailGuidance } from './EmailGuidance' import { t, Trans } from '@lingui/macro' -import { useQuery } from '@apollo/client' +import { useMutation, useQuery } from '@apollo/client' import { DOMAIN_GUIDANCE_PAGE } from '../graphql/queries' +import { FAVOURITE_DOMAIN } from '../graphql/mutations' import { LoadingMessage } from '../components/LoadingMessage' import { ErrorFallbackMessage } from '../components/ErrorFallbackMessage' import { useUserVar } from '../utilities/userState' @@ -36,12 +38,19 @@ import { RequestOrgInviteModal } from '../organizations/RequestOrgInviteModal' import { OrganizationCard } from '../organizations/OrganizationCard' import { ErrorBoundary } from 'react-error-boundary' import { UserIcon } from '../theme/Icons' +import { useDocumentTitle } from '../utilities/useDocumentTitle' function GuidancePage() { const { isOpen, onOpen, onClose } = useDisclosure() - const { domainSlug: domain } = useParams() + const { domainSlug: domain, activeTab } = useParams() + const toast = useToast() + const tabNames = ['web-guidance', 'email-guidance', 'additional-findings'] + const defaultActiveTab = tabNames[0] + const { loading, error, data } = useQuery(DOMAIN_GUIDANCE_PAGE, { variables: { domain: domain }, + fetchPolicy: 'cache-and-network', + nextFetchPolicy: 'cache-only', errorPolicy: 'all', }) @@ -52,9 +61,10 @@ function GuidancePage() { const [orgInfo, setOrgInfo] = useState({}) const { + id: domainId, domain: domainName, web: webScan, - additionalFindings, + hasDMARCReport, dnsScan, mxRecordDiff, organizations, @@ -62,8 +72,48 @@ function GuidancePage() { rcode, status, userHasPermission, + webScanPending, + wildcardSibling, } = data?.findDomainByDomain || {} + useDocumentTitle(`${domainName}`) + + const changeActiveTab = (index) => { + const tab = tabNames[index] + if (activeTab !== tab) { + history.replace(`/domains/${domain}/${tab}`) + } + } + + useEffect(() => { + if (!activeTab) { + history.replace(`/domains/${domain}/${defaultActiveTab}`) + } + }, [activeTab, history, domainName, defaultActiveTab]) + + const [favouriteDomain, { _loading, _error }] = useMutation(FAVOURITE_DOMAIN, { + onError: ({ message }) => { + toast({ + title: t`An error occurred while favouriting a domain.`, + description: message, + status: 'error', + duration: 9000, + isClosable: true, + position: 'top-left', + }) + }, + onCompleted() { + toast({ + title: t`Favourited Domain`, + description: t`You have successfully added ${domainName} to myTracker.`, + status: 'success', + duration: 9000, + isClosable: true, + position: 'top-left', + }) + }, + }) + if (loading) { return ( @@ -186,7 +236,13 @@ function GuidancePage() { ) guidanceResults = ( - + changeActiveTab(i)} + isLazy + > Web Guidance @@ -196,11 +252,9 @@ function GuidancePage() { - {additionalFindings && ( - - Additional Findings - - )} + + Additional Findings + @@ -226,11 +280,9 @@ function GuidancePage() { - {additionalFindings && ( - - - - )} + + + @@ -252,12 +304,12 @@ function GuidancePage() { {domainName.toUpperCase()} - {data.findDomainByDomain.webScanPending && ( + {webScanPending && ( Scan Pending )} - {data.findDomainByDomain.wildcardSibling && ( + {wildcardSibling && ( @@ -266,8 +318,19 @@ function GuidancePage() { )} + {isLoggedIn() && ( + { + await favouriteDomain({ variables: { domainId } }) + }} + variant="primary" + aria-label={`favourite ${domainName}`} + icon={} + ml="2" + /> + )} {isLoggedIn() && isEmailValidated() && } - {data.findDomainByDomain.hasDMARCReport && ( + {hasDMARCReport && (