A block for administrators, managers and teachers to simplify navigation in Moodle. Contains easy access links to most used functions. Block's content is based on user's role & capabilities and page context.
GNU General Public License v3.0
0
stars
0
forks
source link
Plugin automatically creates undeletable instance upon installation #2
I expect this was well intended as a nice feature. However, I actually consider it a bug.
In the xmldb_block_mmquicklink_install() function, a new instance of the block is created and marked as undeletable.
It is setting the parent context to "1". There is no guarantee that the SYSCONTEXTID is exactly this.
Why is the block added to the undeletableblocktypes ? That setting was supposed to protect essential blocks only such as Navigation or Administration that could not be re-added easily.
Let me suggest to re-consider this whole function.
I expect this was well intended as a nice feature. However, I actually consider it a bug.
In the
xmldb_block_mmquicklink_install()
function, a new instance of the block is created and marked as undeletable.SYSCONTEXTID
is exactly this.undeletableblocktypes
? That setting was supposed to protect essential blocks only such as Navigation or Administration that could not be re-added easily.Let me suggest to re-consider this whole function.