|
|
@@ -139,7 +139,7 @@ func GetAttachment(ctx *context.Context) { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
if repository == nil { //If not linked |
|
|
if repository == nil { //If not linked |
|
|
if !(ctx.IsSigned && attach.UploaderID == ctx.User.ID) { //We block if not the uploader |
|
|
|
|
|
|
|
|
if !(ctx.IsSigned && attach.UploaderID == ctx.User.ID) && attach.IsPrivate { //We block if not the uploader |
|
|
ctx.Error(http.StatusNotFound) |
|
|
ctx.Error(http.StatusNotFound) |
|
|
return |
|
|
return |
|
|
} |
|
|
} |
|
|
|