Fix double div bug