Fix issue where sometimes no form elements loaded because of race condition.