Code refactoring, looks slightly better now it has less indentation

Signed-off-by: Darkrulerz <Dark_rulerz@hotmail.com>