diff --git a/src/algorithms/graph/kruskal/kruskal.js b/src/algorithms/graph/kruskal/kruskal.js index 3f0ac44f..dd9968a0 100644 --- a/src/algorithms/graph/kruskal/kruskal.js +++ b/src/algorithms/graph/kruskal/kruskal.js @@ -10,7 +10,7 @@ export default function kruskal(graph) { // It should fire error if graph is directed since the algorithm works only // for undirected graphs. if (graph.isDirected) { - throw new Error('Prim\'s algorithms works only for undirected graphs'); + throw new Error('Kruskal\'s algorithms works only for undirected graphs'); } // Init new graph that will contain minimum spanning tree of original graph.