It looks like this is a web page, not a feed. I looked for a feed associated with this page, but couldn't find one. Please enter the address of your feed to validate.

Source: https://xosq.shop/ticket/2393?format=rss

  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml">
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  <head>
  12.    <title>
  13.      #2393 (bbp_user_can_view_forum() and custom user ID)
  14.     – bbPress Trac
  15.    </title>
  16.      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
  17.      <meta http-equiv="X-UA-Compatible" content="IE=edge" />
  18.    <!--[if IE]><script type="text/javascript">
  19.      if (/^#__msie303:/.test(window.location.hash))
  20.        window.location.replace(window.location.hash.replace(/^#__msie303:/, '#'));
  21.    </script><![endif]-->
  22.          <link rel="search" href="/search" />
  23.          <link rel="prev" href="/ticket/2392" title="Ticket #2392" />
  24.          <link rel="last" href="/ticket/3609" title="Ticket #3609" />
  25.          <link rel="help" href="/wiki/TracGuide" />
  26.          <link rel="alternate" href="/ticket/2393?format=csv" type="text/csv" class="csv" title="Comma-delimited Text" />
  27.          <link rel="alternate" href="/ticket/2393?format=tab" type="text/tab-separated-values" class="tab" title="Tab-delimited Text" />
  28.          <link rel="alternate" href="/ticket/2393?format=rss" type="application/rss+xml" class="rss" title="RSS Feed" />
  29.          <link rel="next" href="/ticket/2395" title="Ticket #2395" />
  30.          <link rel="start" href="/wiki" />
  31. <link rel="stylesheet" href="https://s.w.org/style/trac/common/css/trac.css?v=220" />
  32. <link rel="stylesheet" href="https://s.w.org/style/trac/common/css/ticket.css?v=220" />
  33. <link rel="stylesheet" href="https://s.w.org/style/trac/common/css/jquery-ui/jquery-ui.css?v=220" />
  34. <link rel="stylesheet" href="https://s.w.org/style/trac/common/css/jquery-ui-addons.css?v=220" />
  35.          <link rel="icon" href="https://bbpress.org/favicon.ico" type="image/x-icon" />
  36.          <link rel="first" href="/ticket/1" title="Ticket #1" />
  37.    <style id="trac-noscript" type="text/css">.trac-noscript { display: none !important }</style>
  38.      <link type="application/opensearchdescription+xml" rel="search" href="/search/opensearch" title="Search bbPress Trac" />
  39.    <script type="text/javascript">
  40.      var auto_preview_timeout=2.0;
  41.      var form_token="7c124ad8d416c31d8f607b30";
  42.      var jquery_ui={"ampm":true,"date_format":"mm/dd/yy","day_names":{"abbreviated":["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],"narrow":["Su","Mo","Tu","We","Th","Fr","Sa"],"wide":["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},"default_timezone":null,"first_week_day":0,"month_names":{"abbreviated":["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],"wide":["January","February","March","April","May","June","July","August","September","October","November","December"]},"period_names":{"am":["AM","AM"],"pm":["PM","PM"]},"show_timezone":false,"time_format":"hh:mm:ss TT","timepicker_separator":" ","timezone_iso8601":false,"timezone_list":null};
  43.      var comments_prefs={"comments_order":"oldest","show_comments":"true","show_prop_changes":"true"};
  44.    </script>
  45. <link rel="dns-prefetch" href="//fonts.googleapis.com" />
  46. <link rel="dns-prefetch" href="//www.googletagmanager.com" />
  47. <script>//<![CDATA[
  48. (function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
  49. new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
  50. j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
  51. 'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
  52. })(window,document,'script','dataLayer','GTM-P24PF4B');
  53. //]]></script>
  54. <link rel="stylesheet" href="//fonts.googleapis.com/css?family=Open+Sans%3A300italic%2C400italic%2C600italic%2C300%2C400%2C600&amp;subset=latin%2Clatin-ext&amp;ver=3.8.1-alpha" type="text/css" media="all" />
  55. <link type="text/css" media="screen" rel="stylesheet" href="//bbpress.org/wp-content/themes/bb-base/style.css?v=24" />
  56. <link type="text/css" media="screen" rel="stylesheet" href="//bbpress.org/wp-content/themes/bb-base/style-bbpress.css?v=24" />
  57.  
  58. <meta name="viewport" content="width=device-width" />
  59. <link rel="stylesheet" href="https://s.w.org/wp-includes/css/dashicons.min.css?20150710" type="text/css" />
  60. <link rel="stylesheet" type="text/css" href="https://s.w.org/style/trac/wp-trac.css?220" />
  61. <script src="https://s.w.org/style/trac/common/js/jquery.js?v=220"></script>
  62. <link rel="canonical" href="https://bbpress.trac.wordpress.org/ticket/2393" />
  63. <script src="https://s.w.org/style/trac/common/js/babel.js?v=220"></script>
  64. <script src="https://s.w.org/style/trac/common/js/trac.js?v=220"></script>
  65. <script src="https://s.w.org/style/trac/common/js/search.js?v=220"></script>
  66. <script src="https://s.w.org/style/trac/common/js/folding.js?v=220"></script>
  67. <script src="https://s.w.org/style/trac/common/js/wikitoolbar.js?v=220"></script>
  68. <script src="https://s.w.org/style/trac/common/js/resizer.js?v=220"></script>
  69. <script src="https://s.w.org/style/trac/common/js/auto_preview.js?v=220"></script>
  70. <script src="https://s.w.org/style/trac/common/js/jquery-ui.js?v=220"></script>
  71. <script src="https://s.w.org/style/trac/common/js/jquery-ui-addons.js?v=220"></script>
  72. <script src="https://s.w.org/style/trac/common/js/jquery-ui-i18n.js?v=220"></script>
  73.    <script type="text/javascript">
  74.      jQuery("#trac-noscript").remove();
  75.      jQuery(document).ready(function($) {
  76.        $(".trac-autofocus").focus();
  77.        $(".trac-target-new").attr("target", "_blank");
  78.        if ($.ui) { /* is jquery-ui added? */
  79.          $(".trac-datepicker:not([readonly])").prop("autocomplete", "off").datepicker();
  80.          $(".trac-datetimepicker:not([readonly])").prop("autocomplete", "off").datetimepicker();
  81.          $("#main").addClass("trac-nodatetimehint");
  82.        }
  83.        $(".trac-disable").disableSubmit(".trac-disable-determinant");
  84.        setTimeout(function() { $(".trac-scroll").scrollToTop() }, 1);
  85.        $(".trac-disable-on-submit").disableOnSubmit();
  86.      });
  87.    </script>
  88. <script src="https://s.w.org/style/trac/common/js/threaded_comments.js?v=220"></script>
  89.    <script type="text/javascript">
  90.      jQuery(document).ready(function($) {
  91.        $("div.description").find("h1,h2,h3,h4,h5,h6").addAnchor(_("Link to this section"));
  92.        $(".foldable").enableFolding(false, true);
  93.      /*<![CDATA[*/
  94.        $("#attachments").toggleClass("collapsed");
  95.        $("#trac-up-attachments").click(function () {
  96.          $("#attachments").removeClass("collapsed");
  97.          return true;
  98.        });
  99.        $("#modify").parent().toggleClass("collapsed");
  100.        $(".trac-topnav a").click(function() { $("#modify").parent().removeClass("collapsed"); });
  101.        function setRevertHandler() {
  102.          $("button.trac-revert").click(function() {
  103.            var div = $("div", this);
  104.            var field_name = div[0].id.substr(7);
  105.            var field_value = div.text();
  106.            var input = $("#propertyform *[name=field_" + field_name + "]");
  107.            if (input.length > 0) {
  108.              if (input.filter("input[type=radio]").length > 0) {
  109.                input.val([field_value]);
  110.              } else if (input.filter("input[type=checkbox]").length > 0) {
  111.                input.val(field_value == "1" ? [field_value] : []);
  112.              } else {
  113.                input.val(field_value);
  114.              }
  115.            } else { // Special case for CC checkbox
  116.              input = $("#propertyform input[name=cc_update]").val([]);
  117.            }
  118.            input.change();
  119.            // Remove the revert button
  120.            if ($(this).closest("tbody").children("tr").length === 1)
  121.              $(this).closest(".trac-change-panel").remove();
  122.            else
  123.              $(this).closest("tr").remove();
  124.            return false;
  125.          });
  126.        }
  127.        setRevertHandler();
  128.        var comment_focused = false;
  129.        $("#comment").focus(function() { comment_focused = true; })
  130.                     .blur(function() { comment_focused = false; });
  131.        $("#propertyform").autoSubmit({preview: '1'}, function(data, reply) {
  132.          var items = $(reply);
  133.          // Update ticket box
  134.          $("#ticket").replaceWith(items.filter('#ticket'));
  135.          // Replaces content of #changelog, without recreating it
  136.          $("#changelog").empty().append(items.filter("#changelog").contents());
  137.          // Apply comments order and "Show" preferences
  138.          applyCommentsOrder(
  139.            $('#prefs input[name="trac-comments-order"]:checked').val());
  140.          // Show warning
  141.          var new_changes = $("#changelog .trac-new");
  142.          $("#trac-edit-warning").toggle(new_changes.length != 0);
  143.          if (new_changes.length != 0)
  144.            $("#changelog").parent().show().removeClass("collapsed");
  145.          // Update view time
  146.          $("#propertyform input[name='view_time']").replaceWith(items.filter("input[name='view_time']"));
  147.          // Update preview
  148.          var preview = $("#ticketchange").html(items.filter('#preview').children());
  149.          var show_preview = preview.children().length != 0;
  150.          $("#ticketchange").toggle(show_preview);
  151.          setRevertHandler();
  152.          // Execute scripts to load stylesheets
  153.          items.filter("script").appendTo("head");
  154.        }, "#ticketchange .trac-loading");
  155.        $("#trac-comment-editor").autoSubmit({preview_comment: '1'}, function(data, reply) {
  156.          var comment = $("#trac-comment-editor").next("div.comment").html(reply);
  157.          comment.toggle(comment.children().length != 0);
  158.        }, "#changelog .trac-loading");
  159.        /*]]>*/
  160.      });
  161.    </script>
  162.  </head>
  163.  <body id="wordpress-org" class="bbpress trac wporg-make make-bbpress">
  164. <noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-P24PF4B" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
  165.    <dl id="accessibility">
  166.        <dt>Skip to:</dt>
  167.        <dd><a href="#content" title="Skip to content">Content</a></dd>
  168.    </dl>
  169.    <div id="wporg-header">
  170.        <div id="header-inner">
  171. <button id="mobile-menu-button" aria-expanded="false"><span class="screen-reader-text">Toggle Menu</span></button>
  172.            <ul id="wporg-header-menu">
  173.                <li><a href="https://bbpress.org/about/">About</a></li>
  174.                <li><a href="https://bbpress.org/plugins/">Plugins</a></li>
  175.                <li><a href="https://bbpress.org/themes/">Themes</a></li>
  176.                <li><a href="https://codex.bbpress.org/">Documentation</a></li>
  177.                <li><a href="https://bbpress.org/blog/">Blog</a></li>
  178.                <li><a href="https://bbpress.org/forums/">Support</a></li>
  179.                <li class="download"><a href="https://bbpress.org/download/">Download</a></li>
  180.            </ul>
  181.            <h1><a href="https://bbpress.org">bbPress.org</a></h1>
  182.        </div>
  183.    </div>
  184. <div id="subnav">
  185. <div id="subnav-inner">
  186. <ul id="nav-user" class="menu">
  187. <li class="last first">
  188. <a href="https://login.wordpress.org/?redirect_to=https%3A%2F%2Fbbpress.trac.wordpress.org%2Fticket%2F2393" class="login">Login</a>
  189. </li>
  190. </ul>
  191. </div>
  192. </div>
  193. <div id="banner">
  194. <form id="search" action="/search" method="get">
  195.        <div>
  196.          <label for="proj-search">Search:</label>
  197.          <input type="text" id="proj-search" name="q" size="18" value="" />
  198.          <input type="submit" value="Search" />
  199.        </div>
  200.      </form>
  201. </div>
  202.    <div id="mainnav" class="nav">
  203.    <ul>
  204.      <li class="first"><a href="/timeline">Timeline</a></li><li class="active"><a href="/report">View Tickets</a></li><li><a href="/roadmap">Roadmap</a></li><li><a href="/browser">Browse Source</a></li><li class="last"><a href="/ticketgraph">Ticket Graph</a></li>
  205.    </ul>
  206.  </div>
  207.    <div id="main">
  208.      <div id="ctxtnav" class="nav">
  209.        <h2>Context Navigation</h2>
  210.        <ul>
  211.          <li class="first"><span>&larr; <a class="prev" href="/ticket/2392" title="Ticket #2392">Previous Ticket</a></span></li><li class="last"><span><a class="next" href="/ticket/2395" title="Ticket #2395">Next Ticket</a> &rarr;</span></li>
  212.        </ul>
  213.        <hr />
  214.      </div>
  215.    <div id="content" class="ticket">
  216.        <div id="ticket" class="trac-content ">
  217.  <div class="date">
  218.    <p>Opened <a class="timeline" href="/timeline?from=2013-08-24T00%3A28%3A41Z&amp;precision=second" title="See timeline at 08/24/2013 12:28:41 AM">11 years ago</a></p>
  219.    <p>Closed <a class="timeline" href="/timeline?from=2013-11-25T03%3A55%3A12Z&amp;precision=second" title="See timeline at 11/25/2013 03:55:12 AM">11 years ago</a></p>
  220.    <p>Last modified <a class="timeline" href="/timeline?from=2014-01-03T07%3A50%3A53Z&amp;precision=second" title="See timeline at 01/03/2014 07:50:53 AM">11 years ago</a></p>
  221.  </div>
  222.  <h2>
  223.    <a href="/ticket/2393" class="trac-id">#2393</a>
  224.    <span class="trac-status">
  225.      <a href="/query?status=closed">closed</a>
  226.    </span>
  227.    <span class="trac-type">
  228.      <a href="/query?status=!closed&amp;type=defect+(bug)">defect (bug)</a>
  229.    </span>
  230.    <span class="trac-resolution">
  231.      (<a href="/query?status=closed&amp;resolution=fixed">fixed</a>)
  232.    </span>
  233.  </h2>
  234.  <h1 id="trac-ticket-title" class="searchable">
  235.    <span class="summary">bbp_user_can_view_forum() and custom user ID</span>
  236.  </h1>
  237.  <table class="properties">
  238.    <tr>
  239.      <th id="h_reporter">Reported by:</th>
  240.      <td headers="h_reporter" class="searchable">
  241.  <a href="https://profiles.wordpress.org/alex-ye" data-nicename="alex-ye">
  242.    <img class="avatar" src="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=96 2x" height="48" width="48" alt="alex-ye's profile" />
  243.  </a>
  244.    <a class="trac-author" href="/query?status=!closed&amp;reporter=alex-ye">alex-ye</a>
  245. </td>
  246.      <th id="h_owner">Owned by:</th>
  247.      <td headers="h_owner">
  248.  <a href="https://profiles.wordpress.org/johnjamesjacoby">
  249.    <img class="avatar" src="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=96 2x" height="48" width="48" alt="johnjamesjacoby's profile" />
  250.  </a>
  251.    <a class="trac-author" href="/query?status=!closed&amp;owner=johnjamesjacoby">johnjamesjacoby</a>
  252. </td>
  253.    </tr>
  254.    <tr>
  255.        <th id="h_milestone">
  256.          Milestone:
  257.        </th>
  258.        <td headers="h_milestone">
  259.              <a class="closed milestone" href="/milestone/2.5" title="Completed 11 years ago (11/25/2013 06:27:23 AM)">2.5</a>
  260.        </td>
  261.        <th id="h_priority">
  262.          Priority:
  263.        </th>
  264.        <td headers="h_priority">
  265.              <a href="/query?status=!closed&amp;priority=normal">normal</a>
  266.        </td>
  267.    </tr><tr>
  268.        <th id="h_severity">
  269.          Severity:
  270.        </th>
  271.        <td headers="h_severity">
  272.              <a href="/query?status=!closed&amp;severity=normal">normal</a>
  273.        </td>
  274.        <th id="h_version">
  275.          Version:
  276.        </th>
  277.        <td headers="h_version">
  278.              <a href="/query?status=!closed&amp;version=2.3.2">2.3.2</a>
  279.        </td>
  280.    </tr><tr>
  281.        <th id="h_component">
  282.          Component:
  283.        </th>
  284.        <td headers="h_component">
  285.              <a href="/query?status=!closed&amp;component=Component+-+Users">Component - Users</a>
  286.        </td>
  287.        <th id="h_keywords">
  288.          Keywords:
  289.        </th>
  290.        <td headers="h_keywords" class="searchable">
  291.              <a href="/query?status=!closed&amp;keywords=~has-patch">has-patch</a>
  292.        </td>
  293.    </tr><tr>
  294.        <th id="h_cc" class="missing">
  295.          Cc:
  296.        </th>
  297.        <td headers="h_cc" class="searchable">
  298.        </td>
  299.        <th class="missing">
  300.        </th>
  301.        <td>
  302.        </td>
  303.    </tr>
  304.  </table>
  305.  <div class="description">
  306.    <h3 id="comment:description">
  307.      Description
  308.    </h3>
  309.    <div class="searchable">
  310.      <p>
  311. A small bug in <code>bbp_user_can_view_forum()</code> , it doesn't work properly with a custom user ID. because it doesn't pass the $user_id variable to <code>bbp_is_user_keymaster()</code> check. <br />
  312. </p>
  313.  
  314.    </div>
  315.  </div>
  316. </div>
  317.          
  318.    <div id="attachments">
  319.        <h3 class="foldable">Attachments <span class="trac-count">(2)</span></h3>
  320.        <div class="attachments">
  321.          <dl class="attachments">
  322.              <dt>
  323.    <a href="/attachment/ticket/2393/template.php.patch" title="View attachment">template.php.patch</a><a href="/raw-attachment/ticket/2393/template.php.patch" class="trac-rawlink" title="Download">​</a> (<span title="854 bytes">854 bytes</span>) - added by <span class="trac-author">alex-ye</span> <a class="timeline" href="/timeline?from=2013-08-24T00%3A32%3A38Z&amp;precision=second" title="See timeline at 08/24/2013 12:32:38 AM">11 years ago</a>.
  324.  </dt>
  325.              <dt>
  326.    <a href="/attachment/ticket/2393/2393.patch" title="View attachment">2393.patch</a><a href="/raw-attachment/ticket/2393/2393.patch" class="trac-rawlink" title="Download">​</a> (<span title="707 bytes">707 bytes</span>) - added by <span class="trac-author">alex-ye</span> <a class="timeline" href="/timeline?from=2013-09-03T04%3A26%3A00Z&amp;precision=second" title="See timeline at 09/03/2013 04:26:00 AM">11 years ago</a>.
  327.  </dt>
  328.          </dl>
  329.          <p>
  330.            Download all attachments as: <a rel="nofollow" href="/zip-attachment/ticket/2393/">.zip</a>
  331.          </p>
  332.          
  333.        </div>
  334.    </div>
  335.  
  336.        <div>
  337.          <div class="trac-noscript" style="position: relative">
  338.            <form id="prefs" method="get" action="/prefs" style="position: absolute; right: 0">
  339.              <div id="trac-comments-order">
  340.                <input type="radio" id="trac-comments-oldest" name="trac-comments-order" value="oldest" checked="checked" />
  341.                <label for="trac-comments-oldest">Oldest first</label>
  342.                <input type="radio" id="trac-comments-newest" name="trac-comments-order" value="newest" />
  343.                <label for="trac-comments-newest">Newest first</label>
  344.                <span id="trac-threaded-toggle" style="display: none">
  345.                  <input type="radio" id="trac-comments-threaded" name="trac-comments-order" value="threaded" />
  346.                  <label for="trac-comments-threaded">Threaded</label>
  347.                </span>
  348.              </div>
  349.              <div>
  350.                <input id="trac-show-comments-toggle" type="checkbox" checked="checked" />
  351.                <label for="trac-show-comments-toggle">Show comments</label>
  352.                <input id="trac-show-property-changes-toggle" type="checkbox" />
  353.                <label for="trac-show-property-changes-toggle">Show property changes</label>
  354.              </div>
  355.            </form>
  356.          </div>
  357.          <h3 class="foldable">Change History <span class="trac-count">(18)</span></h3>
  358.          <div id="changelog">
  359.              <div class="change">
  360.                
  361.  <h3 class="change">
  362.    <span class="threading">
  363.    </span>
  364.        <span class="avatar">
  365.          <span class="username-line"><a href="https://profiles.wordpress.org/alex-ye" class="profile-link">
  366.            <img src="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="alex-ye" data-nicename="alex-ye"><span class="trac-author">alex-ye</span></span></a></span>
  367.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-08-24T00%3A32%3A38Z&amp;precision=second" title="See timeline at 08/24/2013 12:32:38 AM">11 years</a> ago</span>
  368.        </span>
  369.    <div class="trac-ticket-buttons">
  370.    </div>
  371.  </h3>
  372.  <div class="trac-ticket-buttons"></div>
  373.  <ul class="changes">
  374.    <li class="trac-field-attachment">
  375.      <strong class="trac-field-attachment">Attachment</strong>
  376.        <a href="/attachment/ticket/2393/template.php.patch"><em>template.php.patch</em></a><a href="/raw-attachment/ticket/2393/template.php.patch" title="Download" class="trac-rawlink">​</a>
  377.          added
  378.    </li>
  379.  </ul>
  380.  
  381.              </div>
  382.              <div class="change" id="trac-change-1-1377353402182867">
  383.                
  384.  <h3 class="change">
  385.    <span class="threading">
  386.      <span id="comment:1" class="cnum">
  387.    <a href="#comment:1">#1</a>
  388.  </span>
  389.    </span>
  390.        <span class="avatar">
  391.          <span class="username-line"><a href="https://profiles.wordpress.org/johnjamesjacoby" class="profile-link">
  392.            <img src="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="johnjamesjacoby" data-nicename="johnjamesjacoby"><span class="trac-author">johnjamesjacoby</span></span></a></span>
  393.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-08-24T14%3A10%3A02Z&amp;precision=second" title="See timeline at 08/24/2013 02:10:02 PM">11 years</a> ago</span>
  394.        </span>
  395.    <div class="trac-ticket-buttons">
  396.    </div>
  397.  </h3>
  398.  <div class="trac-ticket-buttons"></div>
  399.  <ul class="changes">
  400.    <li class="trac-field-milestone">
  401.      <strong class="trac-field-milestone">Milestone</strong>
  402.        changed from <em>Awaiting Review</em> to <em>2.4</em>
  403.    </li>
  404.  </ul>
  405.    <div class="comment searchable">
  406.      <p>
  407. Thanks for the patch. Committing.<br />
  408. </p>
  409.  
  410.    </div>
  411.  
  412.              </div>
  413.              <div class="change" id="trac-change-2-1377353566469641">
  414.                
  415.  <h3 class="change">
  416.    <span class="threading">
  417.      <span id="comment:2" class="cnum">
  418.    <a href="#comment:2">#2</a>
  419.  </span>
  420.    </span>
  421.        <span class="avatar">
  422.          <span class="username-line"><a href="https://profiles.wordpress.org/johnjamesjacoby" class="profile-link">
  423.            <img src="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="johnjamesjacoby" data-nicename="johnjamesjacoby"><span class="trac-author">johnjamesjacoby</span></span></a></span>
  424.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-08-24T14%3A12%3A46Z&amp;precision=second" title="See timeline at 08/24/2013 02:12:46 PM">11 years</a> ago</span>
  425.        </span>
  426.    <div class="trac-ticket-buttons">
  427.    </div>
  428.  </h3>
  429.  <div class="trac-ticket-buttons"></div>
  430.  <ul class="changes">
  431.    <li class="trac-field-owner">
  432.      <strong class="trac-field-owner">Owner</strong>
  433.        set to <em>johnjamesjacoby</em>
  434.    </li><li class="trac-field-resolution">
  435.      <strong class="trac-field-resolution">Resolution</strong>
  436.        set to <em>fixed</em>
  437.    </li><li class="trac-field-status">
  438.      <strong class="trac-field-status">Status</strong>
  439.        changed from <em>new</em> to <em>closed</em>
  440.    </li>
  441.  </ul>
  442.    <div class="comment searchable">
  443.      <p>
  444. In <a class="changeset" href="/changeset/5087" title="In bbp_user_can_view_forum(), pass the $user_id into ...">5087</a>:<br />
  445. </p>
  446. <div class="message"><p>
  447. In bbp_user_can_view_forum(), pass the $user_id into bbp_is_user_keymaster().<br />
  448. </p>
  449. <p>
  450. Fixes issue where bbp_user_can_view_forum() may return incorrect results for users with the Keymaster role.<br />
  451. </p>
  452. <p>
  453. Props alex-ye. Fixes <a class="closed ticket" href="/ticket/2393" title="#2393: defect (bug): bbp_user_can_view_forum() and custom user ID (closed: fixed)">#2393</a>.<br />
  454. </p>
  455. </div>
  456.    </div>
  457.  
  458.              </div>
  459.              <div class="change">
  460.                
  461.  <h3 class="change">
  462.    <span class="threading">
  463.    </span>
  464.        <span class="avatar">
  465.          <span class="username-line"><a href="https://profiles.wordpress.org/alex-ye" class="profile-link">
  466.            <img src="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="alex-ye" data-nicename="alex-ye"><span class="trac-author">alex-ye</span></span></a></span>
  467.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-09-03T04%3A26%3A00Z&amp;precision=second" title="See timeline at 09/03/2013 04:26:00 AM">11 years</a> ago</span>
  468.        </span>
  469.    <div class="trac-ticket-buttons">
  470.    </div>
  471.  </h3>
  472.  <div class="trac-ticket-buttons"></div>
  473.  <ul class="changes">
  474.    <li class="trac-field-attachment">
  475.      <strong class="trac-field-attachment">Attachment</strong>
  476.        <a href="/attachment/ticket/2393/2393.patch"><em>2393.patch</em></a><a href="/raw-attachment/ticket/2393/2393.patch" title="Download" class="trac-rawlink">​</a>
  477.          added
  478.    </li>
  479.  </ul>
  480.  
  481.              </div>
  482.              <div class="change" id="trac-change-3-1378182467098483">
  483.                
  484.  <h3 class="change">
  485.    <span class="threading">
  486.      <span id="comment:3" class="cnum">
  487.    <a href="#comment:3">#3</a>
  488.  </span>
  489.          <span>follow-up:</span>
  490.    <a href="#comment:6" class="follow-up">↓ 6</a>
  491.    </span>
  492.        <span class="avatar">
  493.          <span class="username-line"><a href="https://profiles.wordpress.org/alex-ye" class="profile-link">
  494.            <img src="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="alex-ye" data-nicename="alex-ye"><span class="trac-author">alex-ye</span></span></a></span>
  495.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-09-03T04%3A27%3A47Z&amp;precision=second" title="See timeline at 09/03/2013 04:27:47 AM">11 years</a> ago</span>
  496.        </span>
  497.    <div class="trac-ticket-buttons">
  498.    </div>
  499.  </h3>
  500.  <div class="trac-ticket-buttons"></div>
  501.  <ul class="changes">
  502.    <li class="trac-field-resolution">
  503.      <strong class="trac-field-resolution">Resolution</strong>
  504.        <em>fixed</em> deleted
  505.    </li><li class="trac-field-status">
  506.      <strong class="trac-field-status">Status</strong>
  507.        changed from <em>closed</em> to <em>reopened</em>
  508.    </li>
  509.  </ul>
  510.    <div class="comment searchable">
  511.      <p>
  512. The above patch fixing another bug when you pass <code>user_id</code> as zero.<br />
  513. </p>
  514.  
  515.    </div>
  516.  
  517.              </div>
  518.              <div class="change" id="trac-change-4-1378190623460640">
  519.                
  520.  <h3 class="change">
  521.    <span class="threading">
  522.      <span id="comment:4" class="cnum">
  523.    <a href="#comment:4">#4</a>
  524.  </span>
  525.    </span>
  526.        <span class="avatar">
  527.          <span class="username-line"><a href="https://profiles.wordpress.org/netweb" class="profile-link">
  528.            <img src="https://wordpress.org/grav-redirect.php?user=netweb&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=netweb&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="netweb" data-nicename="netweb"><span class="trac-author">netweb</span></span></a></span>
  529.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-09-03T06%3A43%3A43Z&amp;precision=second" title="See timeline at 09/03/2013 06:43:43 AM">11 years</a> ago</span>
  530.        </span>
  531.    <div class="trac-ticket-buttons">
  532.    </div>
  533.  </h3>
  534.  <div class="trac-ticket-buttons"></div>
  535.  <ul class="changes">
  536.    <li class="trac-field-milestone">
  537.      <strong class="trac-field-milestone">Milestone</strong>
  538.        <em>2.4</em> deleted
  539.    </li>
  540.  </ul>
  541.  
  542.              </div>
  543.              <div class="change" id="trac-change-5-1378190753048229">
  544.                
  545.  <h3 class="change">
  546.    <span class="threading">
  547.      <span id="comment:5" class="cnum">
  548.    <a href="#comment:5">#5</a>
  549.  </span>
  550.    </span>
  551.        <span class="avatar">
  552.          <span class="username-line"><a href="https://profiles.wordpress.org/netweb" class="profile-link">
  553.            <img src="https://wordpress.org/grav-redirect.php?user=netweb&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=netweb&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="netweb" data-nicename="netweb"><span class="trac-author">netweb</span></span></a></span>
  554.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-09-03T06%3A45%3A53Z&amp;precision=second" title="See timeline at 09/03/2013 06:45:53 AM">11 years</a> ago</span>
  555.        </span>
  556.    <div class="trac-ticket-buttons">
  557.    </div>
  558.  </h3>
  559.  <div class="trac-ticket-buttons"></div>
  560.  <ul class="changes">
  561.    <li class="trac-field-milestone">
  562.      <strong class="trac-field-milestone">Milestone</strong>
  563.        set to <em>Awaiting Review</em>
  564.    </li>
  565.  </ul>
  566.  
  567.              </div>
  568.              <div class="change" id="trac-change-6-1378439707384167">
  569.                
  570.  <h3 class="change">
  571.    <span class="threading">
  572.      <span id="comment:6" class="cnum">
  573.    <a href="#comment:6">#6</a>
  574.  </span>
  575.        in reply to:
  576.    <a href="#comment:3">↑ 3</a>
  577.        ;
  578.          <span>follow-up:</span>
  579.    <a href="#comment:7" class="follow-up">↓ 7</a>
  580.    </span>
  581.        <span class="avatar">
  582.          <span class="username-line"><a href="https://profiles.wordpress.org/johnjamesjacoby" class="profile-link">
  583.            <img src="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="johnjamesjacoby" data-nicename="johnjamesjacoby"><span class="trac-author">johnjamesjacoby</span></span></a></span>
  584.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-09-06T03%3A55%3A07Z&amp;precision=second" title="See timeline at 09/06/2013 03:55:07 AM">11 years</a> ago</span>
  585.        </span>
  586.    <div class="trac-ticket-buttons">
  587.    </div>
  588.  </h3>
  589.  <div class="trac-ticket-buttons"></div>
  590.  <ul class="changes">
  591.    <li class="trac-field-milestone">
  592.      <strong class="trac-field-milestone">Milestone</strong>
  593.        changed from <em>Awaiting Review</em> to <em>2.4.1</em>
  594.    </li>
  595.  </ul>
  596.    <div class="comment searchable">
  597.      <p>
  598. Replying to <a class="ticket" href="/ticket/2393#comment:3" title="Comment 3">alex-ye</a>:<br />
  599. </p>
  600. <blockquote class="citation">
  601. <p>
  602. The above patch fixing another bug when you pass <code>user_id</code> as zero.<br />
  603. </p>
  604. </blockquote>
  605. <p>
  606. What other bug does this fix?<br />
  607. </p>
  608.  
  609.    </div>
  610.  
  611.              </div>
  612.              <div class="change" id="trac-change-7-1378469014177723">
  613.                
  614.  <h3 class="change">
  615.    <span class="threading">
  616.      <span id="comment:7" class="cnum">
  617.    <a href="#comment:7">#7</a>
  618.  </span>
  619.        in reply to:
  620.    <a href="#comment:6">↑ 6</a>
  621.    </span>
  622.        <span class="avatar">
  623.          <span class="username-line"><a href="https://profiles.wordpress.org/alex-ye" class="profile-link">
  624.            <img src="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="alex-ye" data-nicename="alex-ye"><span class="trac-author">alex-ye</span></span></a></span>
  625.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-09-06T12%3A03%3A34Z&amp;precision=second" title="See timeline at 09/06/2013 12:03:34 PM">11 years</a> ago</span>
  626.        </span>
  627.    <div class="trac-ticket-buttons">
  628.    </div>
  629.  </h3>
  630.  <div class="trac-ticket-buttons"></div>
  631.    <div class="comment searchable">
  632.      <p>
  633. Replying to <a class="ticket" href="/ticket/2393#comment:6" title="Comment 6">johnjamesjacoby</a>:<br />
  634. </p>
  635. <blockquote class="citation">
  636. <p>
  637. Replying to <a class="ticket" href="/ticket/2393#comment:3" title="Comment 3">alex-ye</a>:<br />
  638. </p>
  639. <blockquote class="citation">
  640. <p>
  641. The above patch fixing another bug when you pass <code>user_id</code> as zero.<br />
  642. </p>
  643. </blockquote>
  644. <p>
  645. What other bug does this fix?<br />
  646. </p>
  647. </blockquote>
  648. <p>
  649. The bbPress core doesn't call the the bbp_user_can_view_forum() with <code>user_id</code> as zero, but I face it when I was working on some client plug-in.<br />
  650. </p>
  651. <p>
  652. When you pass the <code>user_id</code> as zero, the developers expect to refer to the current logged-in user ID like the other bbPress functions.<br />
  653. </p>
  654. <p>
  655. so you can describe it as an enhancement.<br />
  656. </p>
  657.  
  658.    </div>
  659.  
  660.              </div>
  661.              <div class="change" id="trac-change-8-1379782816636642">
  662.                
  663.  <h3 class="change">
  664.    <span class="threading">
  665.      <span id="comment:8" class="cnum">
  666.    <a href="#comment:8">#8</a>
  667.  </span>
  668.          <span>follow-up:</span>
  669.    <a href="#comment:9" class="follow-up">↓ 9</a>
  670.    </span>
  671.        <span class="avatar">
  672.          <span class="username-line"><a href="https://profiles.wordpress.org/johnjamesjacoby" class="profile-link">
  673.            <img src="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="johnjamesjacoby" data-nicename="johnjamesjacoby"><span class="trac-author">johnjamesjacoby</span></span></a></span>
  674.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-09-21T17%3A00%3A16Z&amp;precision=second" title="See timeline at 09/21/2013 05:00:16 PM">11 years</a> ago</span>
  675.        </span>
  676.    <div class="trac-ticket-buttons">
  677.    </div>
  678.  </h3>
  679.  <div class="trac-ticket-buttons"></div>
  680.    <div class="comment searchable">
  681.      <p>
  682. Can you detail exactly what bug this causes and how to reproduce it?<br />
  683. </p>
  684.  
  685.    </div>
  686.  
  687.              </div>
  688.              <div class="change" id="trac-change-9-1379841238190312">
  689.                
  690.  <h3 class="change">
  691.    <span class="threading">
  692.      <span id="comment:9" class="cnum">
  693.    <a href="#comment:9">#9</a>
  694.  </span>
  695.        in reply to:
  696.    <a href="#comment:8">↑ 8</a>
  697.        ;
  698.          <span>follow-up:</span>
  699.    <a href="#comment:10" class="follow-up">↓ 10</a>
  700.    </span>
  701.        <span class="avatar">
  702.          <span class="username-line"><a href="https://profiles.wordpress.org/alex-ye" class="profile-link">
  703.            <img src="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="alex-ye" data-nicename="alex-ye"><span class="trac-author">alex-ye</span></span></a></span>
  704.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-09-22T09%3A13%3A58Z&amp;precision=second" title="See timeline at 09/22/2013 09:13:58 AM">11 years</a> ago</span>
  705.        </span>
  706.    <div class="trac-ticket-buttons">
  707.    </div>
  708.  </h3>
  709.  <div class="trac-ticket-buttons"></div>
  710.    <div class="comment searchable">
  711.      <p>
  712. Replying to <a class="ticket" href="/ticket/2393#comment:8" title="Comment 8">johnjamesjacoby</a>:<br />
  713. </p>
  714. <blockquote class="citation">
  715. <p>
  716. Can you detail exactly what bug this causes and how to reproduce it?<br />
  717. </p>
  718. </blockquote>
  719. <p>
  720. It's simple, test this code with a private forum and an user with moderator role:<br />
  721. </p>
  722. <pre class="wiki">echo bbp_user_can_view_forum( array( 'user_id' =&gt; 0, 'forum_id' =&gt; 94 ) );
  723. </pre>
  724.    </div>
  725.  
  726.              </div>
  727.              <div class="change" id="trac-change-10-1380308214064809">
  728.                
  729.  <h3 class="change">
  730.    <span class="threading">
  731.      <span id="comment:10" class="cnum">
  732.    <a href="#comment:10">#10</a>
  733.  </span>
  734.        in reply to:
  735.    <a href="#comment:9">↑ 9</a>
  736.        ;
  737.          <span>follow-up:</span>
  738.    <a href="#comment:12" class="follow-up">↓ 12</a>
  739.    </span>
  740.        <span class="avatar">
  741.          <span class="username-line"><a href="https://profiles.wordpress.org/johnjamesjacoby" class="profile-link">
  742.            <img src="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="johnjamesjacoby" data-nicename="johnjamesjacoby"><span class="trac-author">johnjamesjacoby</span></span></a></span>
  743.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-09-27T18%3A56%3A54Z&amp;precision=second" title="See timeline at 09/27/2013 06:56:54 PM">11 years</a> ago</span>
  744.        </span>
  745.    <div class="trac-ticket-buttons">
  746.    </div>
  747.  </h3>
  748.  <div class="trac-ticket-buttons"></div>
  749.    <div class="comment searchable">
  750.      <p>
  751. Replying to <a class="ticket" href="/ticket/2393#comment:9" title="Comment 9">alex-ye</a>:<br />
  752. </p>
  753. <blockquote class="citation">
  754. <p>
  755. Replying to <a class="ticket" href="/ticket/2393#comment:8" title="Comment 8">johnjamesjacoby</a>:<br />
  756. </p>
  757. <blockquote class="citation">
  758. <p>
  759. Can you detail exactly what bug this causes and how to reproduce it?<br />
  760. </p>
  761. </blockquote>
  762. <p>
  763. It's simple, test this code with a private forum and an user with moderator role:<br />
  764. </p>
  765. <pre class="wiki">echo bbp_user_can_view_forum( array( 'user_id' =&gt; 0, 'forum_id' =&gt; 94 ) );
  766. </pre></blockquote>
  767. <p>
  768. It's not simple, as I still don't understand what the actual bug is. My guess is that <code>bbp_user_can_view_forum</code> needs a fix, more than <code>bbp_get_user_id</code> needing a change in behavior that effects all of bbPress.<br />
  769. </p>
  770. <p>
  771. If you're not passing a user_id into <code>bbp_user_can_view_forum()</code> then it should always return false, since returning true would be double-plus bad. How can a nonexistent user possibly access a forum?<br />
  772. </p>
  773.  
  774.    </div>
  775.  
  776.              </div>
  777.              <div class="change" id="trac-change-11-1380748593856903">
  778.                
  779.  <h3 class="change">
  780.    <span class="threading">
  781.      <span id="comment:11" class="cnum">
  782.    <a href="#comment:11">#11</a>
  783.  </span>
  784.    </span>
  785.        <span class="avatar">
  786.          <span class="username-line"><a href="https://profiles.wordpress.org/johnjamesjacoby" class="profile-link">
  787.            <img src="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="johnjamesjacoby" data-nicename="johnjamesjacoby"><span class="trac-author">johnjamesjacoby</span></span></a></span>
  788.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-10-02T21%3A16%3A33Z&amp;precision=second" title="See timeline at 10/02/2013 09:16:33 PM">11 years</a> ago</span>
  789.        </span>
  790.    <div class="trac-ticket-buttons">
  791.    </div>
  792.  </h3>
  793.  <div class="trac-ticket-buttons"></div>
  794.  <ul class="changes">
  795.    <li class="trac-field-milestone">
  796.      <strong class="trac-field-milestone">Milestone</strong>
  797.        changed from <em>2.4.1</em> to <em>2.5</em>
  798.    </li>
  799.  </ul>
  800.    <div class="comment searchable">
  801.      <p>
  802. Unclear how to reproduce an unexpected circumstance, so moving to 2.5 for more reporter-feedback.<br />
  803. </p>
  804.  
  805.    </div>
  806.  
  807.              </div>
  808.              <div class="change" id="trac-change-12-1380814604153423">
  809.                
  810.  <h3 class="change">
  811.    <span class="threading">
  812.      <span id="comment:12" class="cnum">
  813.    <a href="#comment:12">#12</a>
  814.  </span>
  815.        in reply to:
  816.    <a href="#comment:10">↑ 10</a>
  817.    </span>
  818.        <span class="avatar">
  819.          <span class="username-line"><a href="https://profiles.wordpress.org/alex-ye" class="profile-link">
  820.            <img src="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="alex-ye" data-nicename="alex-ye"><span class="trac-author">alex-ye</span></span></a></span>
  821.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-10-03T15%3A36%3A44Z&amp;precision=second" title="See timeline at 10/03/2013 03:36:44 PM">11 years</a> ago</span>
  822.        </span>
  823.    <div class="trac-ticket-buttons">
  824.    </div>
  825.  </h3>
  826.  <div class="trac-ticket-buttons"></div>
  827.    <div class="comment searchable">
  828.      <p>
  829. Replying to <a class="ticket" href="/ticket/2393#comment:10" title="Comment 10">johnjamesjacoby</a>:<br />
  830. </p>
  831. <blockquote class="citation">
  832. <p>
  833. If you're not passing a user_id into <code>bbp_user_can_view_forum()</code> then it should always return false, since returning true would be double-plus bad.<br />
  834. </p>
  835. </blockquote>
  836. <p>
  837. Currently the function use the logged-in user ID if you don't pass <code>user_id</code> arg.. the bugs happens when you pass <code>user_id</code> arg as <code>0</code> only.<br />
  838. </p>
  839. <p>
  840. What are those bugs?!<br />
  841. When the developer pass <code>user_id</code> as <code>0</code>, he may expect one of those results:<br />
  842. </p>
  843. <p>
  844. 1- The function will return false.<br />
  845. 2- The function will replace the zero <code>user_id</code> with the logged-in user ID.<br />
  846. </p>
  847. <p>
  848. but what actually happens is a mess! <br />
  849. </p>
  850. <ul><li><code>$user_id</code> local variable will have <code>0</code> value.
  851. </li><li><code>bbp_is_user_keymaster( $user_id )</code> will check against the logged-in user ID.
  852. </li><li><code>user_can( $user_id, 'read_private_forums' )</code> check will return<code>false</code>.
  853. </li><li>And <code>apply_filters( 'bbp_user_can_view_forum', $retval, $forum_id, $user_id )</code>
  854. </li></ul><p>
  855. Replying to <a class="ticket" href="/ticket/2393#comment:10" title="Comment 10">johnjamesjacoby</a>:<br />
  856. </p>
  857. <blockquote class="citation">
  858. <p>
  859. How can a nonexistent user possibly access a forum?<br />
  860. </p>
  861. </blockquote>
  862. <p>
  863. Again, there is no security bug in the bbPress core! because bbPress core doesn't pass the <code>user_id</code> as zero with <code>bbp_user_can_view_forum()</code><br />
  864. </p>
  865. <p>
  866. I hope you understand me :)<br />
  867. </p>
  868.  
  869.    </div>
  870.  <div class="trac-lastedit ">
  871.    Last edited <a class="timeline" href="/timeline?from=2013-10-03T15%3A38%3A55Z&amp;precision=second" title="See timeline at 10/03/2013 03:38:55 PM">11 years ago</a>
  872.        by <span class="trac-author">alex-ye</span>
  873.      (<a href="/ticket/2393?cversion=0&amp;cnum_hist=12#comment:12">previous</a>)
  874.      (<a href="/ticket/2393?action=comment-diff&amp;cnum=12&amp;version=1">diff</a>)
  875.  </div>
  876.  
  877.              </div>
  878.              <div class="change" id="trac-change-13-1385350528453085">
  879.                
  880.  <h3 class="change">
  881.    <span class="threading">
  882.      <span id="comment:13" class="cnum">
  883.    <a href="#comment:13">#13</a>
  884.  </span>
  885.    </span>
  886.        <span class="avatar">
  887.          <span class="username-line"><a href="https://profiles.wordpress.org/johnjamesjacoby" class="profile-link">
  888.            <img src="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="johnjamesjacoby" data-nicename="johnjamesjacoby"><span class="trac-author">johnjamesjacoby</span></span></a></span>
  889.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-11-25T03%3A35%3A28Z&amp;precision=second" title="See timeline at 11/25/2013 03:35:28 AM">11 years</a> ago</span>
  890.        </span>
  891.    <div class="trac-ticket-buttons">
  892.    </div>
  893.  </h3>
  894.  <div class="trac-ticket-buttons"></div>
  895.    <div class="comment searchable">
  896.      <p>
  897. In <a class="changeset" href="/changeset/5188" title="In `bbp_user_can_view_forum()` check the `$user_id` before passing it ...">5188</a>:<br />
  898. </p>
  899. <div class="message"><p>
  900. In <code>bbp_user_can_view_forum()</code> check the <code>$user_id</code> before passing it into <code>bbp_is_user_keymaster()</code>. Prevents accidental role escalation if <code>$user_id</code> is empty. See <a class="closed ticket" href="/ticket/2393" title="#2393: defect (bug): bbp_user_can_view_forum() and custom user ID (closed: fixed)">#2393</a>.<br />
  901. </p>
  902. </div>
  903.    </div>
  904.  
  905.              </div>
  906.              <div class="change" id="trac-change-14-1385350880875270">
  907.                
  908.  <h3 class="change">
  909.    <span class="threading">
  910.      <span id="comment:14" class="cnum">
  911.    <a href="#comment:14">#14</a>
  912.  </span>
  913.    </span>
  914.        <span class="avatar">
  915.          <span class="username-line"><a href="https://profiles.wordpress.org/johnjamesjacoby" class="profile-link">
  916.            <img src="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="johnjamesjacoby" data-nicename="johnjamesjacoby"><span class="trac-author">johnjamesjacoby</span></span></a></span>
  917.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-11-25T03%3A41%3A20Z&amp;precision=second" title="See timeline at 11/25/2013 03:41:20 AM">11 years</a> ago</span>
  918.        </span>
  919.    <div class="trac-ticket-buttons">
  920.    </div>
  921.  </h3>
  922.  <div class="trac-ticket-buttons"></div>
  923.    <div class="comment searchable">
  924.      <p>
  925. In <a class="changeset" href="/changeset/5189" title="Check the `$author_id` before passing it into ...">5189</a>:<br />
  926. </p>
  927. <div class="message"><p>
  928. Check the <code>$author_id</code> before passing it into <code>bbp_is_user_keymaster()</code> in blacklist and moderation functions. Prevents accidental role escalation if <code>$author_id</code> is empty. See <a class="closed ticket" href="/ticket/2393" title="#2393: defect (bug): bbp_user_can_view_forum() and custom user ID (closed: fixed)">#2393</a>.<br />
  929. </p>
  930. </div>
  931.    </div>
  932.  
  933.              </div>
  934.              <div class="change" id="trac-change-15-1385351712496756">
  935.                
  936.  <h3 class="change">
  937.    <span class="threading">
  938.      <span id="comment:15" class="cnum">
  939.    <a href="#comment:15">#15</a>
  940.  </span>
  941.    </span>
  942.        <span class="avatar">
  943.          <span class="username-line"><a href="https://profiles.wordpress.org/johnjamesjacoby" class="profile-link">
  944.            <img src="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=johnjamesjacoby&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="johnjamesjacoby" data-nicename="johnjamesjacoby"><span class="trac-author">johnjamesjacoby</span></span></a></span>
  945.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-11-25T03%3A55%3A12Z&amp;precision=second" title="See timeline at 11/25/2013 03:55:12 AM">11 years</a> ago</span>
  946.        </span>
  947.    <div class="trac-ticket-buttons">
  948.    </div>
  949.  </h3>
  950.  <div class="trac-ticket-buttons"></div>
  951.  <ul class="changes">
  952.    <li class="trac-field-resolution">
  953.      <strong class="trac-field-resolution">Resolution</strong>
  954.        set to <em>fixed</em>
  955.    </li><li class="trac-field-status">
  956.      <strong class="trac-field-status">Status</strong>
  957.        changed from <em>reopened</em> to <em>closed</em>
  958.    </li>
  959.  </ul>
  960.    <div class="comment searchable">
  961.      <p>
  962. Marking this as closed.<br />
  963. </p>
  964. <p>
  965. The two above changesets better reflect the intent of <code>bbp_is_user_keymaster()</code> checks, particularly inside of <code>bbp_user_can_view_forum()</code>. <br />
  966. </p>
  967. <p>
  968. If an empty <code>$user_id</code> is explicitly passed as part of the <code>$args</code> array, we do not want to assume the developer intended it to be the current user ID (especially since the default value is already the current user ID.) This is to prevent accidental role escalation, since it is possible you'd want to check if an anonymous user can access a specific forum ID.<br />
  969. </p>
  970. <p>
  971. If I've misunderstood you, please reopen (again) and place in the 2.6 milestone.<br />
  972. </p>
  973. <p>
  974. Thanks for your diligence with this. :)<br />
  975. </p>
  976.  
  977.    </div>
  978.  
  979.              </div>
  980.              <div class="change" id="trac-change-16-1385374821415395">
  981.                
  982.  <h3 class="change">
  983.    <span class="threading">
  984.      <span id="comment:16" class="cnum">
  985.    <a href="#comment:16">#16</a>
  986.  </span>
  987.    </span>
  988.        <span class="avatar">
  989.          <span class="username-line"><a href="https://profiles.wordpress.org/alex-ye" class="profile-link">
  990.            <img src="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=alex-ye&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="alex-ye" data-nicename="alex-ye"><span class="trac-author">alex-ye</span></span></a></span>
  991.            <br /><span class="time-ago"><a class="timeline" href="/timeline?from=2013-11-25T10%3A20%3A21Z&amp;precision=second" title="See timeline at 11/25/2013 10:20:21 AM">11 years</a> ago</span>
  992.        </span>
  993.    <div class="trac-ticket-buttons">
  994.    </div>
  995.  </h3>
  996.  <div class="trac-ticket-buttons"></div>
  997.    <div class="comment searchable">
  998.      <p>
  999. Nice solution John, Always learn from you :)<br />
  1000. </p>
  1001.  
  1002.    </div>
  1003.  
  1004.              </div>
  1005.          </div>
  1006.        </div>
  1007.      <div id="help"><strong>Note:</strong> See
  1008.        <a href="/wiki/TracTickets">TracTickets</a> for help on using
  1009.        tickets.</div>
  1010.    </div>
  1011.    <div id="altlinks">
  1012.    <a class="preferences-link" href="/prefs">Trac UI Preferences</a>
  1013.      <h3>Download in other formats:</h3>
  1014.      <ul>
  1015.        <li class="first">
  1016.          <a rel="nofollow" href="/ticket/2393?format=csv" class="csv">Comma-delimited Text</a>
  1017.        </li><li>
  1018.          <a rel="nofollow" href="/ticket/2393?format=tab" class="tab">Tab-delimited Text</a>
  1019.        </li><li class="last">
  1020.          <a rel="nofollow" href="/ticket/2393?format=rss" class="rss">RSS Feed</a>
  1021.        </li>
  1022.      </ul>
  1023. </div>
  1024.    </div>
  1025. <div id="footer">
  1026. <div class="links">
  1027. <p>
  1028. See also:
  1029. <a href="http://wordpress.org">WordPress.org</a> •
  1030. <a href="http://bbpress.org">bbPress.org</a> •
  1031. <a href="http://buddypress.org">BuddyPress.org</a> •
  1032. <a href="http://ma.tt">Matt</a> •
  1033. <a href="http://bbpress.org/feed/" title="RSS Feed for Articles">Blog RSS</a>
  1034. </p>
  1035. </div>
  1036. <div class="details">
  1037. <p>
  1038. <a href="http://twitter.com/bbpress" class="twitter">Follow bbPress on Twitter</a> •
  1039. <a href="http://bbpress.org/about/gpl/">GPL</a> •
  1040. <a href="http://bbpress.org/contact/">Contact Us</a> •
  1041. <a href="http://bbpress.org/terms/">Terms of Service</a>
  1042. </p>
  1043. </div>
  1044. </div>
  1045. <script>
  1046. var wpTracCurrentUser = "anonymous";
  1047. </script>
  1048. <script src="https://s.w.org/style/js/navigation.min.js?20190128"></script>
  1049. <script src="https://s.w.org/style/trac/jquery.caret.min.js?ver=2015-02-01"></script>
  1050. <script src="https://s.w.org/style/trac/jquery.atwho.min.js?ver=1.0.1"></script>
  1051. <script src="https://s.w.org/style/trac/wp-trac.js?220"></script>
  1052. </body>
  1053. </html>
Copyright © 2002-9 Sam Ruby, Mark Pilgrim, Joseph Walton, and Phil Ringnalda