[+] code refactoring