Adding onInit method for each defined schema