[FIX] Variable referenced before assignment error fixed.