flarum / issue-archive

0 stars 0 forks source link

Unable to approve threads with the approve post permission #92

Open bram1000 opened 3 years ago

bram1000 commented 3 years ago

Bug Report

Current Behavior If a group has the permission to approve posts then they can approve any posts that are not the start of a thread. In order to approve a thread a group also needs the edit post permission.

If a group has the approve post permission but not any edit permissions then they will still get flags about having to approve threads but when they click it they will get an error message: "The requested resource was not found."

Steps to Reproduce

  1. Make a role "moderators" and give it permission to see flags and approve posts
  2. Set all posts by new members to require approval
  3. Create a new user and a moderator account
  4. Create a thread with the new user and log into your moderator account
  5. You will get a flag telling you to approve a thread but can't see the thread

Expected Behavior People with the permission "approve posts" should be able to approve threads.

Environment

Flarum core 0.1.0-beta.15
PHP version: 7.4.3
Loaded extensions: Core, date, libxml, openssl, pcre, zlib, filter, hash, pcntl, Reflection, SPL, session, standard, sodium, mysqlnd, PDO, xml, calendar, ctype, curl, dom, mbstring, FFI, fileinfo, ftp, gd, gettext, iconv, intl, json, ldap, exif, mysqli, pdo_mysql, Phar, posix, readline, shmop, SimpleXML, soap, sockets, sysvmsg, sysvsem, sysvshm, tokenizer, xmlreader, xmlrpc, xmlwriter, xsl, zip, Z end OPcache
+-------------------------------+------------------+--------+
| Flarum Extensions             |                  |        |
+-------------------------------+------------------+--------+
| ID                            | Version          | Commit |
+-------------------------------+------------------+--------+
| flarum-approval               | v0.1.0-beta.15   |        |
| flarum-bbcode                 | v0.1.0-beta.15   |        |
| flarum-emoji                  | v0.1.0-beta.15   |        |
| flarum-lang-english           | v0.1.0-beta.15   |        |
| flarum-flags                  | v0.1.0-beta.15   |        |
| flarum-likes                  | v0.1.0-beta.15   |        |
| flarum-lock                   | v0.1.0-beta.15   |        |
| flarum-markdown               | v0.1.0-beta.15   |        |
| flarum-mentions               | v0.1.0-beta.15   |        |
| flarum-statistics             | v0.1.0-beta.15   |        |
| flarum-sticky                 | v0.1.0-beta.15.1 |        |
| flarum-subscriptions          | v0.1.0-beta.15   |        |
| flarum-suspend                | v0.1.0-beta.15   |        |
| flarum-tags                   | v0.1.0-beta.15   |        |
| fof-upload                    | 0.12.10          |        |
| fof-formatting                | 0.3.1            |        |
| fof-user-bio                  | 0.4.2            |        |
| fof-user-directory            | 0.5.3            |        |
| fof-transliterator            | 0.3.0            |        |
| askvortsov-moderator-warnings | v0.4.2           |        |
| fof-impersonate               | 0.7.0            |        |
| fof-pages                     | 0.6.0            |        |
+-------------------------------+------------------+--------+
Installation path: /var/www/flarum
Debug mode: off
bram1000 commented 3 years ago

This is still an issue in release 1.0.3.

image