done full patch request and clean the code