update the code with a more custom code