LibWeb: Move is_basic_latin() to Blob.{cpp,h}

This method needs to be accessible from both Blob and File.
This commit is contained in:
Kenneth Myhra 2022-08-01 19:33:27 +02:00 committed by Linus Groh
commit 73aec263b1
Notes: sideshowbarker 2024-07-17 14:36:19 +09:00
3 changed files with 10 additions and 9 deletions

View file

@ -8,15 +8,6 @@
namespace Web::FileAPI {
static bool is_basic_latin(StringView view)
{
for (auto code_point : view) {
if (code_point < 0x0020 || code_point > 0x007E)
return false;
}
return true;
}
File::File(ByteBuffer byte_buffer, String file_name, String type, i64 last_modified)
: Blob(move(byte_buffer), move(type))
, m_name(move(file_name))