bring back flag check for testing.