mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 20:29:18 +00:00
LanguageServers/FileDB: Allow m_project_root to be null
This commit is contained in:
parent
c49cf23a86
commit
545b6af305
Notes:
sideshowbarker
2024-07-18 18:10:09 +09:00
Author: https://github.com/itamar8910
Commit: 545b6af305
Pull-request: https://github.com/SerenityOS/serenity/pull/7095
Reviewed-by: https://github.com/awesomekling
1 changed files with 2 additions and 1 deletions
|
@ -67,7 +67,8 @@ String FileDB::to_absolute_path(const String& filename) const
|
|||
if (LexicalPath { filename }.is_absolute()) {
|
||||
return filename;
|
||||
}
|
||||
VERIFY(!m_project_root.is_null());
|
||||
if (m_project_root.is_null())
|
||||
return filename;
|
||||
return LexicalPath { String::formatted("{}/{}", m_project_root, filename) }.string();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue