mirror of
https://github.com/samsonjs/batteries.git
synced 2026-03-25 09:15:46 +00:00
accept a context in extendNative() methods
This commit is contained in:
parent
59e6566d51
commit
8b5841587f
3 changed files with 6 additions and 6 deletions
|
|
@ -3,8 +3,8 @@
|
|||
|
||||
exports.Range = Range;
|
||||
|
||||
exports.extendNative = function() {
|
||||
global.Range = Range;
|
||||
exports.extendNative = function(context) {
|
||||
context.Range = Range;
|
||||
};
|
||||
|
||||
function Range(start, length) {
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@
|
|||
// readable string representations of values
|
||||
exports.repr = repr;
|
||||
|
||||
exports.extendNative = function() {
|
||||
global.repr = repr;
|
||||
exports.extendNative = function(context) {
|
||||
context.repr = repr;
|
||||
};
|
||||
|
||||
function repr(x) {
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@
|
|||
|
||||
exports.Set = Set;
|
||||
|
||||
exports.extendNative = function() {
|
||||
global.Set = Set;
|
||||
exports.extendNative = function(context) {
|
||||
context.Set = Set;
|
||||
};
|
||||
|
||||
var ownProps = Object.getOwnPropertyNames;
|
||||
|
|
|
|||
Loading…
Reference in a new issue