mirror of
https://github.com/Brandon-Rozek/Rozbot.git
synced 2024-11-07 20:30:34 -05:00
8 lines
227 B
JavaScript
8 lines
227 B
JavaScript
var algebrite = require('algebrite');
|
|
var promise = require('promise-polyfill');
|
|
|
|
module.exports = function(expression) {
|
|
return new promise(function(resolve, reject) {
|
|
resolve(algebrite.eval(expression).toString());
|
|
});
|
|
}
|