Fixed bug where the "Execute Routine" link was shown to unprivileged users.

This commit is contained in:
Rouslan Placella 2011-06-10 16:05:38 +01:00
parent aa2692c12f
commit 4a455c3e62

View File

@ -1171,7 +1171,7 @@ function routineMakeRowForList($routine, $ct = 0) {
. '&routine_name=' . urlencode($routine['SPECIFIC_NAME'])
. '">' . $titles['Edit'] . '</a>';
}
if (PMA_currentUserHasPrivilege('EXECUTE', $db)) {
if ($routine['ROUTINE_DEFINITION'] !== NULL && PMA_currentUserHasPrivilege('EXECUTE', $db)) {
// Check if he routine has any input parameters. If it does,
// we will show a dialog to get values for these parameters,
// otherwise we can execute it directly.