Issue #10. Extract 'required query param' check for reuse