Allow answer of archiving service to be an HTTP redirection.
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
7e147012fe
commit
4f78da24b5
|
@ -1,5 +1,5 @@
|
|||
/* This file is part of remwharead.
|
||||
* Copyright © 2019 tastytea <tastytea@tastytea.de>
|
||||
* Copyright © 2019, 2020 tastytea <tastytea@tastytea.de>
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
@ -216,7 +216,14 @@ string URI::make_request(const string &uri, bool archive) const
|
|||
string answer;
|
||||
if (archive)
|
||||
{
|
||||
answer = response.get("Content-Location");
|
||||
if (response.has("Content-Location"))
|
||||
{
|
||||
answer = response.get("Content-Location");
|
||||
}
|
||||
else
|
||||
{
|
||||
answer = uri;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue
Block a user