add migrated check function