Uploaded image for project: 'Wicket'
  1. Wicket
  2. WICKET-3485

Link tries to construct the URL when the link is disabled

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.4.15, 1.5-RC2
    • 1.4.17, 1.5-RC3
    • wicket
    • None

    Description

      This piece of code (Link.onComponentTag) tries to construct the URL for a Link, even when it is disabled:
      CharSequence url = getURL();
      url = appendAnchor(tag, url);
      if (!isLinkEnabled())
      disableLink(tag);
      else

      { use url }

      getURL fails for us, because we did not expect it to be called for a disabled link. The constructed url is never used. Can the getURL and appendAnchor be moved inside the else?

      Attachments

        Activity

          People

            dashorst Martijn Dashorst
            papegaaij Emond Papegaaij
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: