mirror of
https://github.com/google/blockly.git
synced 2026-01-06 16:40:07 +01:00
Minor lints from PR 150.
This commit is contained in:
@@ -110,14 +110,12 @@ Blockly.Blocks['lists_create_with'] = {
|
|||||||
var itemBlock = containerBlock.getInputTargetBlock('STACK');
|
var itemBlock = containerBlock.getInputTargetBlock('STACK');
|
||||||
// Count number of inputs.
|
// Count number of inputs.
|
||||||
var connections = [];
|
var connections = [];
|
||||||
var i = 0;
|
|
||||||
while (itemBlock) {
|
while (itemBlock) {
|
||||||
connections[i] = itemBlock.valueConnection_;
|
connections.push(itemBlock.valueConnection_);
|
||||||
itemBlock = itemBlock.nextConnection &&
|
itemBlock = itemBlock.nextConnection &&
|
||||||
itemBlock.nextConnection.targetBlock();
|
itemBlock.nextConnection.targetBlock();
|
||||||
i++;
|
|
||||||
}
|
}
|
||||||
this.itemCount_ = i;
|
this.itemCount_ = connections.length;
|
||||||
this.updateShape_();
|
this.updateShape_();
|
||||||
// Reconnect any child blocks.
|
// Reconnect any child blocks.
|
||||||
for (var i = 0; i < this.itemCount_; i++) {
|
for (var i = 0; i < this.itemCount_; i++) {
|
||||||
|
|||||||
@@ -127,14 +127,12 @@ Blockly.Blocks['text_join'] = {
|
|||||||
var itemBlock = containerBlock.getInputTargetBlock('STACK');
|
var itemBlock = containerBlock.getInputTargetBlock('STACK');
|
||||||
// Count number of inputs.
|
// Count number of inputs.
|
||||||
var connections = [];
|
var connections = [];
|
||||||
var i = 0;
|
|
||||||
while (itemBlock) {
|
while (itemBlock) {
|
||||||
connections[i] = itemBlock.valueConnection_;
|
connections.push(itemBlock.valueConnection_);
|
||||||
itemBlock = itemBlock.nextConnection &&
|
itemBlock = itemBlock.nextConnection &&
|
||||||
itemBlock.nextConnection.targetBlock();
|
itemBlock.nextConnection.targetBlock();
|
||||||
i++;
|
|
||||||
}
|
}
|
||||||
this.itemCount_ = i;
|
this.itemCount_ = connections.length;
|
||||||
this.updateShape_();
|
this.updateShape_();
|
||||||
// Reconnect any child blocks.
|
// Reconnect any child blocks.
|
||||||
for (var i = 0; i < this.itemCount_; i++) {
|
for (var i = 0; i < this.itemCount_; i++) {
|
||||||
|
|||||||
10
package.json
10
package.json
@@ -23,10 +23,10 @@
|
|||||||
"jshint": "latest"
|
"jshint": "latest"
|
||||||
},
|
},
|
||||||
"jshintConfig": {
|
"jshintConfig": {
|
||||||
"unused": true,
|
"globalstrict": true,
|
||||||
"undef": true,
|
"predef": ["Blockly", "goog", "window", "document", "soy", "XMLHttpRequest"],
|
||||||
"globalstrict": true,
|
"sub": true,
|
||||||
"sub": true,
|
"undef": true,
|
||||||
"predef": ["Blockly", "goog", "window", "document", "soy", "XMLHttpRequest"]
|
"unused": true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user