api controller bug fixed