These are in different view functions.  You do have a point about refactoring, but there's no unnecessary duplication.