Skip to content
This repository was archived by the owner on Apr 3, 2024. It is now read-only.

Add allowExpressions option#244

Merged
matthewloring merged 1 commit intogoogleapis:masterfrom
matthewloring:opt
Mar 7, 2017
Merged

Add allowExpressions option#244
matthewloring merged 1 commit intogoogleapis:masterfrom
matthewloring:opt

Conversation

@matthewloring
Copy link
Copy Markdown
Contributor

No description provided.

@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Feb 22, 2017
Copy link
Copy Markdown
Contributor

@ofrobots ofrobots left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The README examples also need to be modified to always suggest that users set allowExpressions to true.

it('should capture without values when `allowExpressions=false`', function(done) {
// clone a clean breakpointInFoo
var bp = {id: breakpointInFoo.id, location: breakpointInFoo.location};
config.allowExpressions = false;

This comment was marked as spam.

This comment was marked as spam.

debuglet.start();
});

it('should reject breakpoints with conditions when allowExpressions=false',

This comment was marked as spam.

This comment was marked as spam.

debuglet.start();
});

it('should reject breakpoints with expressions when allowExpressions=false',

This comment was marked as spam.

This comment was marked as spam.

varTableIndex: EXPRESSIONS_DISALLOWED_INDEX
});
locals.push({
name: 'locals_not_available',

This comment was marked as spam.

This comment was marked as spam.

This comment was marked as spam.

Copy link
Copy Markdown
Contributor

@ofrobots ofrobots left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM w/ nit + question?

description: null,

/**
* @property {boolean} Whether or not it is safe to evaluate expressions.

This comment was marked as spam.

This comment was marked as spam.

var args = [];
var locals = [];
// Locals and arguments are safe to collect even when `config.allowExpressions=false`
// since we properly avoid inspecting interceptors and getters by default.

This comment was marked as spam.

This comment was marked as spam.

@matthewloring matthewloring merged commit 36a0c2c into googleapis:master Mar 7, 2017
@matthewloring matthewloring deleted the opt branch March 7, 2017 23:10
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants