Sfoglia il codice sorgente

AK: Move the path argument of URL::append_path instead of copying it

Idan Horowitz 3 anni fa
parent
commit
30849b10d5
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. 1 1
      AK/URL.h

+ 1 - 1
AK/URL.h

@@ -74,7 +74,7 @@ public:
     void set_query(String);
     void set_fragment(String);
     void set_cannot_be_a_base_url(bool value) { m_cannot_be_a_base_url = value; }
-    void append_path(String path) { m_paths.append(path); }
+    void append_path(String path) { m_paths.append(move(path)); }
 
     String path() const;
     String basename() const;