Fix Kamada-Kawai layout for graphs with 0 or 1 vertices.