Fixed type check