refactoring: moved talkId validation to middleware => less duplicated code