client/resolving: don't emit error twice, if `beforeError` is unhandled
sample/resolving: add comments and description to options