Add improvement to render and insert method