Fix bug on detail controller