Changed getVertex method to index by String instead of object