Fix checking flex attribute