def to_pint(unit):
    '\n    Some parsing tweaks to fit pint units / handling of edge cases.\n    '
    global HAYSTACK_CONVERSION
    if ((unit == u'per_minute') or (unit == u'/min') or (unit == u'per_second') or (unit == u'/s') or (unit == u'per_hour') or (unit == u'/h') or (unit == None)):
        return ''
    for (haystack_value, pint_value) in HAYSTACK_CONVERSION:
        unit = unit.replace(haystack_value, pint_value)
    return unit
Some parsing tweaks to fit pint units / handling of edge cases.
def to_pint(unit):
    '\n    \n    '
    global HAYSTACK_CONVERSION
    if ((unit == u'per_minute') or (unit == u'/min') or (unit == u'per_second') or (unit == u'/s') or (unit == u'per_hour') or (unit == u'/h') or (unit == None)):
        return 
    for (haystack_value, pint_value) in HAYSTACK_CONVERSION:
        unit = unit.replace(haystack_value, pint_value)
    return unit