fixed weird absolute value issue