add special handling for localhost
v2.0.2