isValidController function

ErrorObject? isValidController(
  1. dynamic input,
  2. String method
)

Implementation

ErrorObject? isValidController(input, String method) {
  ErrorObject? error;
  if (input?.publicKey?.isEmpty ?? true) {
    error = getInternalError(
      InternalErrorKey.MISSING_OR_INVALID,
      context: '$method controller public key should be a string',
    );
  }

  return error;
}