Skip to content

Commit

Permalink
fix reap issue #3
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike Carson committed Apr 6, 2013
1 parent a590a00 commit 42a1ea1
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
5 changes: 5 additions & 0 deletions History.md
Original file line number Diff line number Diff line change
@@ -1,3 1,8 @@
0.1.2 / 2013-04-06
==================

* Fixed reap issue (https://github.com/ca98am79/connect-dynamodb/issues/3)

0.1.1 / 2013-01-26
==================

Expand Down
4 changes: 2 additions & 2 deletions lib/connect-dynamodb.js
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 148,7 @@ module.exports = function(connect){
'S' : sid
},
expires: {
'S' : JSON.stringify(expires)
'N' : JSON.stringify(expires)
},
type: {
'S' : 'connect-session'
Expand Down Expand Up @@ -194,7 194,7 @@ module.exports = function(connect){
function destroy(data, fn) {
var self = this;
function destroyDataAt(index) {
if (data.Count > 0) {
if (data.Count > 0 && index < data.Count) {
var sid = data.Items[index].id.S;
sid = sid.substring(self.prefix.length, sid.length);
self.destroy(sid, function() {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 1,7 @@
{
"name": "connect-dynamodb",
"description": "DynamoDB session store for Connect",
"version": "0.1.1",
"version": "0.1.2",
"author": "Mike Carson <[email protected]> (http://ca98am79.com)",
"main": "./index.js",
"dependencies": {
Expand Down

0 comments on commit 42a1ea1

Please sign in to comment.