Last active
September 24, 2016 17:39
-
-
Save accuervo/d9a3efcef698494539aa0caeb0735e44 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Philosophy of life | |
To install just run npm install life on your heart! | |
*/ | |
var Promise = require("bluebird"); | |
var Life = require("life"); | |
var Growth = require("growth"); | |
Promise.promisifyAll(Life); | |
Promise.promisifyAll(Growth); | |
LifeAsync() | |
.then(function (response){ | |
response.creation ? response.knowledge++ : response.skills++; | |
return GrowthAsync(response); | |
}) | |
.catch(function (error){ | |
error="Learn"; | |
}) | |
.finally(function(){ | |
Life.sense = 😊 ; | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment