Skip to content
Browse files

look for rawhash.node in various places

  • Loading branch information...
1 parent e860475 commit af1078a181e88609db876fc0af2c7d4ff19902b1 @cguerreiro-igalia cguerreiro-igalia committed Jul 26, 2012
Showing with 11 additions and 2 deletions.
  1. +9 −0 index.js
  2. +1 −1 package.json
  3. +1 −1 test.js
View
9 index.js
@@ -0,0 +1,9 @@
+try {
+ module.exports = require('./build/Release/rawhash.node');
+} catch(err) {
+ try {
+ module.exports = require('./build/Debug/rawhash.node');
+ } catch(err) {
+ module.exports = require('./rawhash.node');
+ }
+}
View
2 package.json
@@ -4,7 +4,7 @@
"keywords": ["key:value", "buffer", "store", "in-memory", "cache"],
"homepage": "https://github.com/pconstr/rawhash",
"description": "experimental in-memory key:value cache where keys are binary Buffers",
- "main": "rawhash.node",
+ "main": "index.js",
"repository": {
"type": "git",
"url": "https://github.com/pconstr/rawhash"
View
2 test.js
@@ -6,7 +6,7 @@
'use strict';
var assert = require('assert');
-var rh = require("./rawhash");
+var rh = require("./index.js");
function doTests(h) {
var timeStart = Date.now();

0 comments on commit af1078a

Please sign in to comment.
Something went wrong with that request. Please try again.