version 1.0.40 fixing bugs