Problem/Motivation

If you add a shortcut and it fails for some reason it does send out the following code:

    catch (\Exception $e) {
      drupal_set_message($this->t('Unable to delete the shortcut for %title.', array('%title' => $label)));
    }

The message though is green, even it certainly should not be.

Proposed resolution

Remaining tasks

User interface changes

API changes

Original report by @username

Comments

dawehner’s picture

Issue summary: View changes
Issue tags: +Novice
joshi.rohit100’s picture

Status: Active » Needs review
StatusFileSize
new804 bytes

Added patch for the same.

dawehner’s picture

Status: Needs review » Reviewed & tested by the community

Cool!

wim leers’s picture

Status: Reviewed & tested by the community » Needs work

The IS and patch are for deleting a shortcut inline, but the title is for adding a shortcut inline. This really is about fixing it for both.

Could you also fix ShortcutSetController::addShortcutLinkInline() in a similar way? Thanks :)

rpayanm’s picture

Status: Needs work » Needs review
StatusFileSize
new1.62 KB
wim leers’s picture

Title: ShortCutSetController::addShortcutLinkInline() Unable to add a shortcut should be a warning or even error » Exceptions when adding and deleting shortcut are regular messages, should be error messages
Status: Needs review » Reviewed & tested by the community

Thanks!

Status: Reviewed & tested by the community » Needs work

The last submitted patch, 5: 2371229-5.patch, failed testing.

Status: Needs work » Needs review

rpayanm queued 5: 2371229-5.patch for re-testing.

quietone’s picture

Yes, looks good. Applied patch, and now passes the test that it had failed. I guess that is why it was retested.

wim leers’s picture

Status: Needs review » Reviewed & tested by the community
Issue tags: +php-novice

Must've been a random testbot failure. Good to go :)

alexpott’s picture

Status: Reviewed & tested by the community » Fixed

This issue is a normal bug fix, and doesn't include any disruptive changes, so it is allowed per https://www.drupal.org/core/beta-changes. Committed a924e23 and pushed to 8.0.x. Thanks!

  • alexpott committed a924e23 on 8.0.x
    Issue #2371229 by rpayanm, joshi.rohit100: Exceptions when adding and...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.