Fix double canonical form issue