diff options
author | Andreas Kling <kling@serenityos.org> | 2020-06-03 22:06:21 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-06-03 22:06:52 +0200 |
commit | 21957745f7a6f3b687fbac4f51d7c65ef9e4f0eb (patch) | |
tree | 9dd8f8a7daeab6df823d6936924faf7e5f22c6ba /Libraries/LibWeb | |
parent | 6c09420571f705886ffb38c3d428ea3f990a52f0 (diff) | |
download | serenity-21957745f7a6f3b687fbac4f51d7c65ef9e4f0eb.zip |
LibWeb: Special-case initialization of HTML::AttributeNames::class_
Just do it after all the others instead of trying to be clever.
Diffstat (limited to 'Libraries/LibWeb')
-rw-r--r-- | Libraries/LibWeb/DOM/AttributeNames.cpp | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/Libraries/LibWeb/DOM/AttributeNames.cpp b/Libraries/LibWeb/DOM/AttributeNames.cpp index 8b162d9403..5310670589 100644 --- a/Libraries/LibWeb/DOM/AttributeNames.cpp +++ b/Libraries/LibWeb/DOM/AttributeNames.cpp @@ -41,18 +41,12 @@ void initialize() return; #define __ENUMERATE_HTML_ATTRIBUTE(name) \ - name = #name; \ - if (name.ends_with("_")) \ - name = name.view().substring_view(0, name.length() - 1); + name = #name; ENUMERATE_HTML_ATTRIBUTES #undef __ENUMERATE_HTML_ATTRIBUTE - id = "id"; + // NOTE: Special case for the class attribute since it's a C++ keyword. class_ = "class"; - type = "type"; - href = "href"; - style = "style"; - name = "name"; s_initialized = true; } |