From 58c8352ec2f3c7d03903e801729d6441caaf1de7 Mon Sep 17 00:00:00 2001 From: William Date: Mon, 16 Jul 2018 20:54:30 -0700 Subject: [PATCH] Switch to lodash get. --- lib/classes/Variables.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/classes/Variables.js b/lib/classes/Variables.js index dc8fa4ee3..851fae329 100644 --- a/lib/classes/Variables.js +++ b/lib/classes/Variables.js @@ -691,7 +691,7 @@ class Variables { { useCache: true }) // Use request cache .then(response => BbPromise.resolve(response.Parameter.Value)) .catch((err) => { - if (err.providerError.code !== 'ParameterNotFound') { + if (_.get(err, 'providerError.code') !== 'ParameterNotFound') { return BbPromise.reject(new this.serverless.classes.Error(err.message)); }