serverless-api-gateway-caching
Advanced tools
Comparing version 1.7.2 to 1.7.3-rc1
@@ -0,0 +0,0 @@ { |
{ | ||
"name": "serverless-api-gateway-caching", | ||
"version": "1.7.2", | ||
"version": "1.7.3-rc1", | ||
"description": "A plugin for the serverless framework which helps with configuring caching for API Gateway endpoints.", | ||
@@ -5,0 +5,0 @@ "main": "src/apiGatewayCachingPlugin.js", |
@@ -0,0 +0,0 @@ # serverless-api-gateway-caching |
@@ -26,4 +26,4 @@ 'use strict'; | ||
updateCloudFormationTemplate() { | ||
this.thereIsARestApi = restApiExists(this.serverless, this.settings); | ||
async updateCloudFormationTemplate() { | ||
this.thereIsARestApi = await restApiExists(this.serverless, this.settings); | ||
if (!this.thereIsARestApi) { | ||
@@ -44,4 +44,4 @@ this.serverless.cli.log(`[serverless-api-gateway-caching] No REST API found. Caching settings will not be updated.`); | ||
updateStage() { | ||
this.thereIsARestApi = restApiExists(this.serverless, this.settings); | ||
async updateStage() { | ||
this.thereIsARestApi = await restApiExists(this.serverless, this.settings); | ||
if (!this.thereIsARestApi) { | ||
@@ -48,0 +48,0 @@ this.serverless.cli.log(`[serverless-api-gateway-caching] No REST API found. Caching settings will not be updated.`); |
@@ -0,0 +0,0 @@ const get = require('lodash.get'); |
@@ -0,0 +0,0 @@ const getResourcesByName = (name, serverless) => { |
@@ -10,3 +10,3 @@ 'use strict'; | ||
const restApiExists = (serverless, settings) => { | ||
const restApiExists = async (serverless, settings) => { | ||
if (get(settings, 'restApiId')) { | ||
@@ -23,2 +23,7 @@ return true; | ||
} | ||
const restApiIdFromAlreadyDeployedStack = await retrieveRestApiId(serverless, settings); | ||
if (restApiIdFromAlreadyDeployedStack) { | ||
return true; | ||
} | ||
return false; | ||
@@ -25,0 +30,0 @@ } |
@@ -0,0 +0,0 @@ const isEmpty = require('lodash.isempty'); |
@@ -0,0 +0,0 @@ module.exports = { |
Sorry, the diff of this file is not supported yet
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
39901
594
2