Fixed has_cap warning