You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: checks.go
    path of file: ./repos/gluetun/internal/natpmp
    
    the code of the file until where you have to start completion: package natpmp

import (
	"encoding/binary"
	"errors"
	"fmt"
)

var (
	ErrRequestSizeTooSmall = errors.New("message size is too small")
)

func checkRequest(request []byte) (err error) {
	const minMessageSize = 2 // ve
    
func checkResultCode(resultCode uint16) (err error) {
	switch resultCode {
	case 0:
		return nil
	case 1:
		return fmt.Errorf("%w", ErrVersionNotSupported)
	case 2:
		return fmt.Errorf("%w", ErrNotAuthorized)
	case 3:
		return fmt.Errorf("%w", ErrNetworkFailure)
	case 4:
		return fmt.Errorf("%w", ErrOutOfResources)
	case 5:
		return fmt.Errorf("%w", ErrOperationCodeNotSupported)
	default:
		return fmt.Errorf("%w: %d", ErrResultCodeUnknown, resultCode)
	}
}