Skip to content
This repository has been archived by the owner on Oct 2, 2019. It is now read-only.

Commit

Permalink
Fix #6 - prototype.constructor.
Browse files Browse the repository at this point in the history
  • Loading branch information
mbostock committed Feb 22, 2016
1 parent 751531a commit 0bcd3e8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions src/Diagram.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,8 @@ export default function Diagram(sites, extent) {
}

Diagram.prototype = {
constructor: Diagram,

polygons: function() {
var cells = this.cells,
edges = this.cellEdges,
Expand All @@ -93,6 +95,7 @@ Diagram.prototype = {

return polygons;
},

triangles: function() {
var triangles = [],
edges = this.edges;
Expand All @@ -118,6 +121,7 @@ Diagram.prototype = {

return triangles;
},

links: function() {
return this.edges.filter(function(edge) {
return edge.right;
Expand Down
2 changes: 1 addition & 1 deletion src/RedBlackTree.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ export function RedBlackNode(node) {
}

RedBlackTree.prototype = {
constructor: RedBlackTree,

insert: function(after, node) {
var parent, grandpa, uncle;
Expand Down Expand Up @@ -188,7 +189,6 @@ RedBlackTree.prototype = {

if (node) node.C = false;
}

};

function RedBlackRotateLeft(tree, node) {
Expand Down

0 comments on commit 0bcd3e8

Please sign in to comment.