From 356d295e5f7d9e3268e9566e30eabf7c6de521ab Mon Sep 17 00:00:00 2001 From: Ashwin Phatak Date: Wed, 25 Oct 2017 12:28:09 +0530 Subject: [PATCH] remove setTimeout to repro issue 1255 --- lib/extensions.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/extensions.js b/lib/extensions.js index 3233ae4d..5ce2e759 100644 --- a/lib/extensions.js +++ b/lib/extensions.js @@ -71,13 +71,13 @@ module.exports = function(realmConstructor) { }, (error) => { if (error) { - setTimeout(() => { reject(error); }, 1); + reject(error); } else { try { let syncedRealm = new realmConstructor(config); //FIXME: RN hangs here. Remove when node's makeCallback alternative is implemented - setTimeout(() => { resolve(syncedRealm); }, 1); + resolve(syncedRealm); } catch (e) { reject(e); }