[TikiWiki-commits] [Git][tikiwiki/tiki][29.x] [FIX] ability to print pdf from specific page's edit permission

"Victor Emanouilov \(@kroky\) via TikiWiki-cvs" <[email protected]>
Newsgroups gmane.comp.cms.tiki.cvs
Message-ID <699c39ffe7054_3b186e88277c9@gitlab-sidekiq-low-urgency-cpu-bound-v2-858756f8df-7bptw.mail>

Victor Emanouilov pushed to branch 29.x at Tiki Wiki CMS Groupware / Tiki


Commits:
ada70e1a by Victor Emanouilov at 2026-02-23T13:27:38+02:00
[FIX] ability to print pdf from specific page's edit permission

- - - - -


1 changed file:

- lib/core/Services/PDF/Controller.php


Changes:

=====================================
lib/core/Services/PDF/Controller.php
=====================================
@@ -16,7 +16,12 @@ class Services_PDF_Controller
         global $prefs;
 
         // edit permission is needed to convert arbitrary text to PDF
-        if (! Perms::get()->edit) {
+        if ($input->page->pagename()) {
+            $perms = Perms::get('wiki page', $input->page->pagename());
+        } else {
+            $perms = Perms::get();
+        }
+        if (! $perms->edit) {
             throw new Services_Exception_Denied();
         }
 



View it on GitLab: https://gitlab.com/tikiwiki/tiki/-/commit/ada70e1a82bdd65453534dd1222498250ece4097

-- 
View it on GitLab: https://gitlab.com/tikiwiki/tiki/-/commit/ada70e1a82bdd65453534dd1222498250ece4097
You're receiving this email because of your account on gitlab.com. Manage all notifications: https://gitlab.com/-/profile/notifications | Help: https://gitlab.com/help

_______________________________________________
TikiWiki-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tikiwiki-cvs
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.