mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-01 05:39:11 +00:00
LibURL: Remove the implicit URL constructors
All URLs are now either constucted through the URL Parser or by default constructing a URL, and setting each of the fields of that URL manually. This makes it much more difficult to create invalid URLs.
This commit is contained in:
parent
1a47cfe3b9
commit
de89f5af6d
Notes:
github-actions[bot]
2025-03-04 21:25:54 +00:00
Author: https://github.com/shannonbooth
Commit: de89f5af6d
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/3668
Reviewed-by: https://github.com/trflynn89
2 changed files with 2 additions and 22 deletions
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* Copyright (c) 2018-2020, Andreas Kling <andreas@ladybird.org>
|
||||
* Copyright (c) 2021, Max Wipfli <mail@maxwipfli.ch>
|
||||
* Copyright (c) 2023-2024, Shannon Booth <shannon@serenityos.org>
|
||||
* Copyright (c) 2023-2025, Shannon Booth <shannon@serenityos.org>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
@ -77,15 +77,6 @@ class URL {
|
|||
|
||||
public:
|
||||
URL() = default;
|
||||
URL(StringView);
|
||||
URL(ByteString const& string)
|
||||
: URL(string.view())
|
||||
{
|
||||
}
|
||||
URL(String const& string)
|
||||
: URL(string.bytes_as_string_view())
|
||||
{
|
||||
}
|
||||
|
||||
bool is_valid() const { return m_data->valid; }
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue