From 2a85bfb5d2f3ce03d6a67f4023310140203298a0 Mon Sep 17 00:00:00 2001
From: cgeek <cem.moreau@gmail.com>
Date: Sat, 30 Sep 2017 18:40:43 +0200
Subject: [PATCH] =?UTF-8?q?[fix]=C2=A0Do=20not=20remove=20a=20peer=20from?=
 =?UTF-8?q?=20the=20database?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 app/service/PeeringService.ts | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/app/service/PeeringService.ts b/app/service/PeeringService.ts
index 2e93ff557..0b6528cc3 100644
--- a/app/service/PeeringService.ts
+++ b/app/service/PeeringService.ts
@@ -111,12 +111,6 @@ export class PeeringService {
         if(!found && thePeerDTO.endpoints.length === 0){
           throw 'Peer with zero endpoints that is not already known'
         }
-        if(found && thePeerDTO.endpoints.length === 0){
-          // This peer is saying "I'm no more joinable"
-          // ==> Remove it from the database
-          await this.dal.removePeerByPubkey(thePeerDTO.pubkey)
-          return thePeerDTO
-        }
         else if(found){
           // Already existing peer
           const sp2 = found.block.split('-');
-- 
GitLab