Merge pull request #15990 from rohitwaghchaure/patch_code_refactor

[Minor] Patch fixes