diff options
author | Itamar <itamar8910@gmail.com> | 2021-05-14 09:38:57 +0300 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-05-14 13:27:47 +0200 |
commit | 545b6af3059cc463d27631b729bb6389cfa53c80 (patch) | |
tree | fdb182b5416c7988a4f8c933708bfbf799a29d12 /Userland | |
parent | c49cf23a862cc9564ffaebc8e4dd1c6ef5506bc1 (diff) | |
download | serenity-545b6af3059cc463d27631b729bb6389cfa53c80.zip |
LanguageServers/FileDB: Allow m_project_root to be null
Diffstat (limited to 'Userland')
-rw-r--r-- | Userland/DevTools/HackStudio/LanguageServers/FileDB.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Userland/DevTools/HackStudio/LanguageServers/FileDB.cpp b/Userland/DevTools/HackStudio/LanguageServers/FileDB.cpp index a7afa83ce0..73f74d7d0c 100644 --- a/Userland/DevTools/HackStudio/LanguageServers/FileDB.cpp +++ b/Userland/DevTools/HackStudio/LanguageServers/FileDB.cpp @@ -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(); } |