(vtype)
return vtype
Validate the given type or error.
Validate the given type or error.
Validate the given type or error .
def validate_vtype(vtype) -> str:
    """Validate the given type or error.
    """
    if not vtype:
        raise ValueError("Type parameter missing. It should have one of the "
                "following options: " + ", ".join(volume_type.keys()))
    if vtype not in volume_type.keys():
        raise ValueError("Type has to be one of the following: " +
                ", ".join(volume_type.keys()))
    return vtype
def validate_vtype ( vtype ) -> str : if not vtype : raise ValueError ( "Type parameter missing. It should have one of the " "following options: " + ", " . join ( volume_type . keys ( ) ) ) if vtype not in volume_type . keys ( ) : raise ValueError ( "Type has to be one of the following: " + ", " . join ( volume_type . keys ( ) ) ) return vtype