不要怂,就是干,撸起袖子干!

Commit 9197f74e by Mick Hansen

[feat] add sequelize.escape() convenience method, closes #2484

1 parent fe08b54f
Showing with 12 additions and 0 deletions
# Next # Next
- [BUG] Fixed issue with `order: sequelize.literal('string')` - [BUG] Fixed issue with `order: sequelize.literal('string')`
- [FEATURE] add `clone: true` support to `.get()`. Is needed when using `delete` on values from a `.get()` (`toJSON()`, `this.values`). (.get() is just a reference to the values for performance reasons when there's no custom getters or includes)
- [FEATURE] add `sequelize.escape(value)` convenience method
# 2.0.0-rc6 # 2.0.0-rc6
- [BUG] Fixed issue with including by association reference and where - [BUG] Fixed issue with including by association reference and where
......
...@@ -715,6 +715,16 @@ module.exports = (function() { ...@@ -715,6 +715,16 @@ module.exports = (function() {
}; };
/** /**
* Escape value.
*
* @param {String} value
* @return {String}
*/
Sequelize.prototype.escape = function(value) {
return this.getQueryInterface().escape(value);
};
/**
* Create a new database schema. * Create a new database schema.
* *
* Note,that this is a schema in the [postgres sense of the word](http://www.postgresql.org/docs/9.1/static/ddl-schemas.html), * Note,that this is a schema in the [postgres sense of the word](http://www.postgresql.org/docs/9.1/static/ddl-schemas.html),
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!