История коммитов

simba77
fix(profile): keep a moderator from handing out the ban they are under
A moderator banned from the forum still gave forum bans from the profiles of its members, and so went on moderating the forum the ban closed to them. BanAccess refuses a kind of ban the visitor is under, and now holds every rule of the ban screens: the hierarchy BanHierarchy carried, and whether the visitor may lift a ban or delete its record, which the guards of BanController and the buttons of the history asked separately.

Clearing the history is refused with the same message as deleting a ban: "can be cleared by Supervisor only" was wrong for an account the visitor does not stand above, and for a role the permission was granted to.
simba77
fix(auth): let the ban of a section take the permissions of that section
A ban of a section took nothing away through the permissions, so whatever a section guards by a permission alone stayed open under it: a member banned from the comments still uploaded pictures for news comments, and a moderator banned from the guestbook, the library or the comments went on moderating them. BanVoter now takes away the permissions of the section a ban is for, above what a guest may do, as it does with all of them under the full ban.
simba77
fix(contacts): let a banned member write to the administration
The contact form refused a member banned from the site or from the guestbook, which left them no way to appeal the ban, while a guest could still write there after signing out.
simba77
fix: let a ban of one section leave the others alone
The comments, the photo albums, the votes of karma and the editing of one's own profile closed under a ban of any kind, so a ban of the private messages took away the comments and the albums too. Each of them now asks for the kinds that are about it: the comments for the full ban and the ban of the comments, the library adding its own, everything else for the full ban alone.
simba77
feat(profile): show in the history that the amnesty ended a ban
The amnesty marks the bans it ends in ban_raz, and nothing ever showed the mark: in the history such a ban looked like one that had simply run out.
simba77
refactor(profile): drop the forum post a ban form never received
The form of a ban carried the id of a forum post it was given for, read from ?fid=, but nothing links to the form with one and the id was never stored. Only an empty reason looked at it, so a ban without a reason is now always recorded as given for none.
simba77
fix(profile): keep the bans in force when the history is cleared
Clearing the history of an account deleted every ban it had, the ones still in force among them, which lifted them without a trace, and left their karma penalties behind. It now deletes the bans that have run out or were lifted, each the way deleting it alone does, penalty included.
simba77
fix(profile): take back the karma of a deleted ban only when it cost some
Deleting a ban always took twice the current karma points off the minuses of the account. A ban given while karma was off had cost nothing, so the deletion took away what other members had voted, and a change of the points since made the sum wrong. The penalty the ban recorded is deleted now, if there is one, and by the points it holds.
simba77
fix(profile): lift and delete a ban only of somebody standing below
A ban was given downwards only but lifted by anybody holding the permission, so an administrator could end the ban the supervisor gave another administrator. Lifting a ban, deleting its record and clearing the history now ask the same as giving one (BanHierarchy), which also covers the ban of one's own, and the history offers those buttons only to whoever may press them.
simba77
fix(auth): let a ban close only what it is for
BanVoter refused every permission to an account under a ban of any kind, reading among them: a member banned from the guestbook for an hour could not open the forum, the library or the downloads, which a guest can, and a moderator banned from the library lost the panel. It now acts on the full ban alone and leaves such an account what a guest may do; the supervisor is not locked out. A ban of a section is asked for by that section.

Several places relied on that refusal and asked for no ban themselves. The forum refuses everything that writes in it to an account banned from it or from the site (ForumBanMiddleware on the routes of the signed-in visitor) and offers it no reply, edit or poll form. The library does the same for its articles, their changes and the votes (LibraryAccess), and the downloads take no upload from an account banned from the site (DownloadsAccess).