mightycache
Advanced tools
Comparing version 3.3.0 to 3.3.1
@@ -62,4 +62,4 @@ /* | ||
{ | ||
accessKeyId: this.accessKeyId, | ||
secretAccessKey: this.secretAccessKey | ||
accessKeyId: options.accessKeyId, | ||
secretAccessKey: options.secretAccessKey | ||
} | ||
@@ -66,0 +66,0 @@ ); |
{ | ||
"name": "mightycache", | ||
"version": "3.3.0", | ||
"version": "3.3.1", | ||
"description": "Module providing multiple implementations of a cache backed by a data store.", | ||
@@ -13,9 +13,9 @@ "keywords": [ | ||
], | ||
"homepage": "http://github.com/RiptideCloud/mightycache", | ||
"homepage": "http://github.com/RiptideElements/mightycache", | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/RiptideCloud/mightycache" | ||
"url": "https://github.com/RiptideElements/mightycache" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/RiptideCloud/mightycache/issues" | ||
"url": "https://github.com/RiptideElements/mightycache/issues" | ||
}, | ||
@@ -38,8 +38,3 @@ "author": { | ||
], | ||
"licenses": [ | ||
{ | ||
"type": "MIT", | ||
"url": "http://www.opensource.org/licenses/MIT" | ||
} | ||
], | ||
"license": "MIT", | ||
"main": "index.js", | ||
@@ -46,0 +41,0 @@ "dependencies": { |
# Mighty Cache | ||
[![npm](https://img.shields.io/npm/v/mightycache.svg)](https://www.npmjs.com/package/mightycache) | ||
[![npm](https://img.shields.io/npm/dm/mightycache.svg)](https://www.npmjs.com/package/mightycache) | ||
[![Build Status](https://travis-ci.org/RiptideCloud/mightycache.svg?branch=master)](https://travis-ci.org/RiptideCloud/mightycache) | ||
[![Coverage Status](https://img.shields.io/coveralls/RiptideCloud/mightycache.svg)](https://coveralls.io/r/RiptideCloud/mightycache) | ||
[![Build Status](https://travis-ci.org/RiptideElements/mightycache.svg?branch=master)](https://travis-ci.org/RiptideElements/mightycache) | ||
[![Coverage Status](https://img.shields.io/coveralls/RiptideElements/mightycache.svg)](https://coveralls.io/r/RiptideElements/mightycache) | ||
[![Codacy](https://img.shields.io/codacy/e15e6fda7ab3418e8d5573ad32f97a8b.svg)](https://www.codacy.com/public/davidtpate/mightycache) | ||
[![Code Climate](https://codeclimate.com/github/RiptideCloud/mightycache/badges/gpa.svg)](https://codeclimate.com/github/RiptideCloud/mightycache) | ||
[![David](https://img.shields.io/david/RiptideCloud/mightycache.svg)](https://david-dm.org/RiptideCloud/mightycache) | ||
[![David](https://img.shields.io/david/dev/RiptideCloud/mightycache.svg)](https://david-dm.org/RiptideCloud/mightycache) | ||
[![David](https://img.shields.io/david/peer/RiptideCloud/mightycache.svg)](https://david-dm.org/RiptideCloud/mightycache) | ||
[![Code Climate](https://codeclimate.com/github/RiptideElements/mightycache/badges/gpa.svg)](https://codeclimate.com/github/RiptideElements/mightycache) | ||
[![David](https://img.shields.io/david/RiptideElements/mightycache.svg)](https://david-dm.org/RiptideElements/mightycache) | ||
[![David](https://img.shields.io/david/dev/RiptideElements/mightycache.svg)](https://david-dm.org/RiptideElements/mightycache) | ||
[![David](https://img.shields.io/david/peer/RiptideElements/mightycache.svg)](https://david-dm.org/RiptideElements/mightycache) | ||
@@ -12,0 +12,0 @@ Module providing multiple implementations of a cache backed by a data store. |
@@ -31,2 +31,4 @@ /* | ||
bucketName, | ||
originalAccessKeyId, | ||
originalSecretAccessKey, | ||
cachesToTest = [ | ||
@@ -238,5 +240,9 @@ { | ||
before: function () { | ||
originalAccessKeyId = process.env.AWS_ACCESS_KEY_ID; | ||
process.env.AWS_ACCESS_KEY_ID = ''; | ||
originalSecretAccessKey = process.env.AWS_SECRET_ACCESS_KEY; | ||
process.env.AWS_SECRET_ACCESS_KEY = ''; | ||
s3Credentials = { | ||
accessKeyId: process.env.AWS_ACCESS_KEY_ID, | ||
secretAccessKey: process.env.AWS_SECRET_KEY, | ||
accessKeyId: originalAccessKeyId, | ||
secretAccessKey: originalSecretAccessKey, | ||
region: process.env.AWS_REGION | ||
@@ -246,2 +252,3 @@ }; | ||
delete require.cache['aws-sdk']; | ||
s3fsImpl = require('s3fs')(bucketName, s3Credentials); | ||
@@ -252,2 +259,4 @@ | ||
after: function () { | ||
process.env.AWS_ACCESS_KEY_ID = originalAccessKeyId; | ||
process.env.AWS_SECRET_ACCESS_KEY = originalSecretAccessKey; | ||
return s3fsImpl.destroy(); | ||
@@ -276,5 +285,9 @@ }, | ||
before: function () { | ||
originalAccessKeyId = process.env.AWS_ACCESS_KEY_ID; | ||
process.env.AWS_ACCESS_KEY_ID = ''; | ||
originalSecretAccessKey = process.env.AWS_SECRET_ACCESS_KEY; | ||
process.env.AWS_SECRET_ACCESS_KEY = ''; | ||
s3Credentials = { | ||
accessKeyId: process.env.AWS_ACCESS_KEY_ID, | ||
secretAccessKey: process.env.AWS_SECRET_KEY, | ||
accessKeyId: originalAccessKeyId, | ||
secretAccessKey: originalSecretAccessKey, | ||
region: process.env.AWS_REGION | ||
@@ -284,2 +297,3 @@ }; | ||
delete require.cache['aws-sdk']; | ||
s3fsImpl = require('s3fs')(bucketName, s3Credentials); | ||
@@ -290,2 +304,4 @@ | ||
after: function () { | ||
process.env.AWS_ACCESS_KEY_ID = originalAccessKeyId; | ||
process.env.AWS_SECRET_ACCESS_KEY = originalSecretAccessKey; | ||
return s3fsImpl.destroy(); | ||
@@ -292,0 +308,0 @@ }, |
@@ -29,3 +29,2 @@ /* | ||
s3fsImpl, | ||
s3Credentials, | ||
bucketName, | ||
@@ -68,10 +67,5 @@ cachesToTest = [ | ||
before: function () { | ||
s3Credentials = { | ||
accessKeyId: process.env.AWS_ACCESS_KEY_ID, | ||
secretAccessKey: process.env.AWS_SECRET_KEY, | ||
region: process.env.AWS_REGION | ||
}; | ||
bucketName = 'mightycache-s3-setImpl-test-bucket-' + (Math.random() + '').slice(2, 8); | ||
s3fsImpl = require('s3fs')(bucketName, s3Credentials); | ||
s3fsImpl = require('s3fs')(bucketName); | ||
@@ -86,7 +80,4 @@ return s3fsImpl.create(); | ||
{ | ||
bucket: bucketName, | ||
accessKeyId: s3Credentials.accessKeyId, | ||
secretAccessKey: s3Credentials.secretAccessKey | ||
} | ||
)); | ||
bucket: bucketName | ||
})); | ||
} | ||
@@ -93,0 +84,0 @@ }, |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
Found 1 instance in 1 package
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
Found 1 instance in 1 package
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
170977
3429
27