make add note work correctly