Mutation function implemented properly