Update StarDirectives.cpp
This commit is contained in:
parent
51d6e63dfe
commit
c992d4f72a
@ -98,8 +98,10 @@ void Directives::loadOperations() const {
|
||||
}
|
||||
|
||||
void Directives::parse(String&& directives) {
|
||||
if (directives.empty())
|
||||
if (directives.empty()) {
|
||||
shared.reset();
|
||||
return;
|
||||
}
|
||||
|
||||
List<Entry> newList;
|
||||
StringView view(directives);
|
||||
@ -123,8 +125,10 @@ void Directives::parse(String&& directives) {
|
||||
}
|
||||
});
|
||||
|
||||
if (newList.empty() && !prefix.empty())
|
||||
if (newList.empty() && !prefix.empty()) {
|
||||
shared.reset();
|
||||
return;
|
||||
}
|
||||
|
||||
shared = std::make_shared<Shared const>(move(newList), move(directives), prefix);
|
||||
if (view.size() < 1000) { // Pre-load short enough directives
|
||||
|
Loading…
Reference in New Issue
Block a user