def remove_quotes(path):
    """
    Removes the quotes surrounding the given string, if any

    :param path: A string
    :return: The string without surrounding quotes
    """
    if not path:
        return path

    for quote in ('"', "'"):
        if path[0] == path[-1] == quote:
            return path[1:-1]

    return path