From 62425158453169f37e366c492c48e036a214eb85 Mon Sep 17 00:00:00 2001
From: Bastien Dumont <bdumont@grandlyon.com>
Date: Fri, 9 Jun 2023 10:42:29 +0200
Subject: [PATCH] retours

---
 src/helpers/parsing.js | 2 +-
 src/requests/bo.js     | 3 +--
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/src/helpers/parsing.js b/src/helpers/parsing.js
index 75d8c71..420c444 100644
--- a/src/helpers/parsing.js
+++ b/src/helpers/parsing.js
@@ -184,7 +184,7 @@ function parsePointId(pointId) {
   } else if (strPointId.length === 13) {
     return `0${strPointId}`
   } else {
-    throw new Error(`PointId ${pointId} is not malformed`)
+    throw new Error(`PointId ${pointId} is malformed`)
   }
 }
 
diff --git a/src/requests/bo.js b/src/requests/bo.js
index b984a75..7b938ed 100644
--- a/src/requests/bo.js
+++ b/src/requests/bo.js
@@ -34,11 +34,10 @@ async function createBoConsent(
   }
 
   try {
-    const pdl = parseInt(pointID)
     const { data } = await axios.post(
       `${url}/consent`,
       {
-        pdl,
+        pointID,
         lastname,
         firstname,
         address,
-- 
GitLab