color fix | checkdat function