fixed the Integer conversion for Double values