mirror of
https://github.com/strapi/strapi.git
synced 2026-01-06 12:13:52 +00:00
Merge pull request #4191 from FailedSitcom/master
Fix image url when using a third party
This commit is contained in:
commit
8e2a6ec256
@ -182,7 +182,11 @@ module.exports = {
|
||||
return ctx.notFound('file.notFound');
|
||||
}
|
||||
|
||||
data.url = strapi.config.url + data.url;
|
||||
// if is local server upload, add backend host as prefix
|
||||
if (data.url[0] === '/') {
|
||||
data.url = strapi.config.url + data.url;
|
||||
}
|
||||
|
||||
ctx.send(data);
|
||||
},
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user