fixed bug in entries controller