update code documentation for clarity