fixed controller bug