diff --git a/Userland/Libraries/LibIDL/IDLParser.cpp b/Userland/Libraries/LibIDL/IDLParser.cpp index b616cc8dbf6..44f803352a8 100644 --- a/Userland/Libraries/LibIDL/IDLParser.cpp +++ b/Userland/Libraries/LibIDL/IDLParser.cpp @@ -831,10 +831,10 @@ static void resolve_typedef(Interface& interface, NonnullRefPtr& type, Has bool nullable = type->is_nullable(); type = it->value.type; type->set_nullable(nullable); - if (!extended_attributes) - return; - for (auto& attribute : it->value.extended_attributes) - extended_attributes->set(attribute.key, attribute.value); + if (extended_attributes) { + for (auto& attribute : it->value.extended_attributes) + extended_attributes->set(attribute.key, attribute.value); + } // Recursively resolve typedefs in unions after we resolved the type itself - e.g. for this: // typedef (A or B) Union1;