parseContentAddressMethodPrefix: use string_view

Co-authored-by: John Ericson <git@JohnEricson.me>
This commit is contained in:
Robert Hensing 2020-09-17 22:04:05 +02:00 committed by Robert Hensing
parent 8279178b07
commit fbf509c113

View file

@ -52,7 +52,7 @@ std::string renderContentAddressMethod(ContentAddressMethod cam) {
Parses content address strings up to the hash.
*/
static ContentAddressMethod parseContentAddressMethodPrefix(std::string_view & rest) {
std::string wholeInput(rest);
std::string_view wholeInput { rest };
std::string_view prefix;
{