MCPcopy
hub / github.com/scrapy/scrapy / _to_bytes_or_none

Function _to_bytes_or_none

scrapy/mail.py:49–52  ·  view source on GitHub ↗
(text: str | bytes | None)

Source from the content-addressed store, hash-verified

47
48
49def _to_bytes_or_none(text: str | bytes | None) -> bytes | None:
50 if text is None:
51 return None
52 return to_bytes(text)
53
54
55warnings.warn(

Callers 1

__init__Method · 0.85

Calls 1

to_bytesFunction · 0.90

Tested by

no test coverage detected