mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-03 07:07:23 +00:00
AK: Rename span() to bytes() when appropriate.
I originally defined the bytes() method for the String class, because it made it obvious that it's a span of bytes instead of span of characters. This commit makes this more consistent by defining a bytes() method when the type of the span is known to be u8. Additionaly, the cast operator to Bytes is overloaded for ByteBuffer and such.
This commit is contained in:
@@ -727,7 +727,7 @@ bool TLSv12::add_client_key(const ByteBuffer& certificate_pem_buffer, const Byte
|
||||
if (certificate_pem_buffer.is_empty() || rsa_key.is_empty()) {
|
||||
return true;
|
||||
}
|
||||
auto decoded_certificate = decode_pem(certificate_pem_buffer.span(), 0);
|
||||
auto decoded_certificate = decode_pem(certificate_pem_buffer, 0);
|
||||
if (decoded_certificate.is_empty()) {
|
||||
dbg() << "Certificate not PEM";
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user