The changes in this method has not been used at the end, but I left them because they don't break anything and can be useful i nthe future