got rid of weird versions of floyd warshall, default case works fine