Skip to content
Snippets Groups Projects

Display error if user can't read requested sub

Merged Rick Parrish requested to merge cant-read-sub into master
1 unresolved thread
1 file
+ 7
0
Compare changes
  • Side-by-side
  • Inline
@@ -145,6 +145,13 @@ if (typeof http_request.query.notice !== 'undefined') {
writeln(format(strings.notice_box, http_request.query.notice[0]));
}
if (typeof http_request.query.sub !== 'undefined' &&
typeof msg_area.sub[http_request.query.sub[0]] !== 'undefined' &&
!msg_area.sub[http_request.query.sub[0]].can_read
) {
writeln('<div class="alert alert-danger">Sorry, you do not have access to the requested sub.</div>');
}
if (typeof http_request.query.sub !== 'undefined' &&
typeof msg_area.sub[http_request.query.sub[0]] !== 'undefined' &&
typeof http_request.query.thread !== 'undefined' &&
Loading