[6518]
|
johnjamesjacoby
|
Engagements: Update `bbp_add_user_object()`.
* New phpdoc description
* Add `$unique` parameter and default to `true` (this differs from the normal `false` default of `add_metadata()` because, by default, this API assumes no 1 user can have multiple relationships with the same object)
* Pass `$unique` into `apply_filters()`
See #3068.
|
[6516]
|
johnjamesjacoby
|
Engagements: Update `bbp_update_topic_voice_count()` to only count the number of existing engagements.
Recalculating the entire engagement tree for each topic is costly, should be done in its own dedicated function, and then only hooked in or executed when absolutely necessary.
This is easier to do with the engagements API that's new in 2.6. Recalculation function imminent.
See #3068.
|
[6521]
|
johnjamesjacoby
|
Engagements: Update phpdoc for `bbp_add_user_to_object()`.
* Replace `add_post_meta()` with `add_metadata()`
See #3068.
|
[6530]
|
johnjamesjacoby
|
Engagements: Update topic engagements when they are manually inserted.
This brings the `_insert_` functions up to date with the `_new_` equivalents.
See: #3068. Props netweb & unit-tests for catching this.
|
[6330]
|
johnjamesjacoby
|
Engagements: Updates existing functions & unit tests:
* Correct tests so that `post_author` of 0 does not get included in the overall count
* Add user IDs to all topics & replies where voice counts are being tested
* Update voice-count update function to use the new user-relationships API
* Clean-up topic merge code to more efficiently migrate favorites, subscriptions, and engagements
See #3068.
|
[6520]
|
johnjamesjacoby
|
Engagements: Updates to phpdoc & helper functions.
* New function to remove all users from an object
* New function to remove all users from all objects
* Remove references to taxonomy term storage (from original implementation)
* Update phpdoc with more accurate descriptions of intended parameter usages
See #3068.
|
[6723]
|
johnjamesjacoby
|
Engagements: abstract meta strategy into an overload'able class.
This change introduces a class and wrapper function to allow the `meta` strategy of the new user engagements API to be hot-swapped. This might be helpful on large installations where a dedicated database table makes more sense, or for integrations where features like "Favorites" or "Subscriptions" might already be delegated to other third-party membership plugins. Now, the caller class can be filtered to one that includes custom methods.
See #3068.
|
[6992]
|
johnjamesjacoby
|
Engagements: add caching to User strategy, for 2.5 compatibility.
This commit re-adds query caching for `FIND_IN_SET` queries, fixing long pageloads on sites with large amounts of usermeta that are unable to run the 2.6 database upgrade routine(s).
Props johnjamesjacoby, netweb. Fixes #3292. For 2.6.3, branches/2.6.
|
[6993]
|
johnjamesjacoby
|
Engagements: add caching to User strategy, for 2.5 compatibility.
This commit re-adds query caching for `FIND_IN_SET` queries, fixing long pageloads on sites with large amounts of usermeta that are unable to run the 2.6 database upgrade routine(s).
Props johnjamesjacoby, netweb. Fixes #3292. For 2.7, trunk.
|
[6914]
|
johnjamesjacoby
|
Engagements: always show user avatars in subscription/favorite metaboxes.
This commit introduces a helper function (to reduce code duplication) responsible for looping through queried users and outputting avatars and profile links.
A developers note is included in the function docs discouraging third-party plugin developers from using it, as future iterations of bbPress may modify its output without notice.
Fixes #3272.
|
[6877]
|
johnjamesjacoby
|
Engagements: demystify strategy sanitization.
This change ensures that invalid/unavailable strategies are never used, and also allows for custom strategies to exist (custom table, etc...) without requiring strategy registration.
See #3211.
|
[6843]
|
johnjamesjacoby
|
Engagements: documentation improvements to various strategy classes.
See #3211.
|
[6828]
|
johnjamesjacoby
|
Engagements: enforce `absint()` on function parameters in engagements API.
Also fixes a bug causing an `array_search()` to erroneously fail.
See #3206.
|
[7003]
|
johnjamesjacoby
|
Engagements: explicitly query for `-1` posts if no objects are known to exist.
This commit fixes an issue with the 2.5 User Engagements strategy that will cause all topics to be queried instead of none of them.
|
[7002]
|
johnjamesjacoby
|
Engagements: explicitly query for `-1` posts if no objects are known to exist.
This commit fixes an issue with the 2.5 User Engagements strategy that will cause all topics to be queried instead of none of them.
|
[7005]
|
johnjamesjacoby
|
Engagements: explicitly query for `-1` posts if no objects are known to exist.
This commit fixes an issue with the 2.5 User Engagements strategy that will cause all topics to be queried instead of none of them.
Revert r7002 and use a different syntax to avoid debug notices.
|
[7004]
|
johnjamesjacoby
|
Engagements: explicitly query for `-1` posts if no objects are known to exist.
This commit fixes an issue with the 2.5 User Engagements strategy that will cause all topics to be queried instead of none of them.
Revert r7003 and use a different syntax to avoid debug notices.
|
[6844]
|
johnjamesjacoby
|
Engagements: first pass at back-compat for pre-2.6 subscriptions and favorites
Introduces a `BBP_User_Engagements_Back_Compat` class with the necessary inverted methods to add/remove engagement relationships.
Needs testing, and `get_query()` left todo.
See #3211.
|
[7023]
|
johnjamesjacoby
|
Engagements: fix bugs with caching implementation in User strategy.
This commit adds the `$object_id` to the end of the cache key, to avoid collisions with other IDs. It also loosens 2 explicit `true` comparisons because internal calls to `update_meta()` up the stack may return an integer.
See #3292. For 2.6.4, branches/2.6.
|
[7024]
|
johnjamesjacoby
|
Engagements: fix bugs with caching implementation in User strategy.
This commit adds the `$object_id` to the end of the cache key, to avoid collisions with other IDs. It also loosens 2 explicit `true` comparisons because internal calls to `update_meta()` up the stack may return an integer.
See #3292. For 2.7, trunk.
|
[6739]
|
johnjamesjacoby
|
Engagements: include `BBP_User_Engagements_Term` class, as term storage example.
This change includes an alternative storage mechanism for engagements. Meta is used by default, but using Taxonomies and Terms for storage instead may be more appealing to certain installation types.
A few related functions were updated to use newer abstractions. See #459.
|
[6842]
|
johnjamesjacoby
|
Engagements: move common classes out of abstraction.php.
See #3211.
|
[6876]
|
johnjamesjacoby
|
Engagements: next pass at back-compat for pre-2.6 `user` strategy.
* Renames `BBP_User_Engagements_Back_Compat` to `BBP_User_Engagements_User` so the approach is more clear.
* Fill in `get_query()` method, left todo from r6844.
* Move active strategy into a preloaded option, default to `meta`
* Set active strategy to `user` on failed auto-upgrade to 2.6 to maintain backwards compatibility
* Introduces sub-actions to assist with abstracting the engagement strategy setup
Fixes #3211.
|
[7012]
|
johnjamesjacoby
|
Engagements: stop shouting.
This commit removes the last remaining exclamation mark from some engagements feedback.
Props casiepa. Fixes #3293. For 2.6.3, branches/2.6.
|
[7013]
|
johnjamesjacoby
|
Engagements: stop shouting.
This commit removes the last remaining exclamation mark from some engagements feedback.
Props casiepa. Fixes #3293. For 2.7, trunk.
|
[7026]
|
johnjamesjacoby
|
Engagements: update cache groups in User strategy.
This commit makes all cache groups the same, and adds an inline comment about zero value object IDs. It also fixes a performance issue with pre-2.6 non-upgraded databases causing FIND_IN_SET queries not to be retrieved from cache correctly.
See #3292. For 2.6.4, branches/2.6.
|
[7025]
|
johnjamesjacoby
|
Engagements: update cache groups in User strategy.
This commit makes all cache groups the same, and adds an inline comment about zero value object IDs. It also fixes a performance issue with pre-2.6 non-upgraded databases causing FIND_IN_SET queries not to be retrieved from cache correctly.
See #3292. For 2.7, trunk.
|
[3494]
|
johnjamesjacoby
|
Enhancements to core slug conflict checker. Add context to item args te better hint where conflict is.
|
[4671]
|
johnjamesjacoby
|
Enqueue jQuery in default templates, to fix issue with head scripts not having jQuery available in shortcodes, or places where TinyMCE might be pulled into the theme.
|
[3084]
|
johnjamesjacoby
|
Enqueue the default style.css for twentyten parent template now that bbp-twentyten is a child theme again.
|
[3335]
|
johnjamesjacoby
|
Ensure $bbp global is in $GLOBALS
|
[4777]
|
johnjamesjacoby
|
Ensure network admins can always view group forum forms. Props thebrandonallen. Fixes #2214.
|
[4825]
|
johnjamesjacoby
|
Ensure textarea content shows correct return $_POST value by adding stripslashes() to bbp_get_form_*_content() functions.
|
[3189]
|
johnjamesjacoby
|
Ensure that author avatars appear at the top of the reply area, for theme compat.
|
[3420]
|
johnjamesjacoby
|
Ensure that default role exists, and default to 'read' cap if it does not.
|
[6062]
|
johnjamesjacoby
|
Escape `display_name` field usages in `bbp_get_author_link()`.
|
[6063]
|
johnjamesjacoby
|
Escape `display_name` field usages in `bbp_get_author_link()`. (2.5 branch)
|
[4952]
|
johnjamesjacoby
|
Escape output of translation strings where appropriate. Refresh some escaping approaches. See #1999.
|
[6141]
|
johnjamesjacoby
|
Even less shouting, plus a grammar sweep.
* Remove contractions
* Update weird sounding English phrases (like "the permissions" to "permission")
* Simplify some phrases to be less wordy
* Update "permission" error codes to all use "permission" instead of also "permissions"
* Add comma to "Oh bother!". See: https://www.youtube.com/watch?v=Fhl4oKvxphs
|
[5799]
|
netweb
|
Example importer: Change AIM, YIM, and Jabber profile fields to generic examples with meta key prefixes
Props netweb. See #2815
|
[5580]
|
netweb
|
Example importer: Include Subscribed Forums, Subscribed Topics and Favourite Topics
Props netweb. See #2668
|
[5672]
|
netweb
|
Exclude BuddyPress tests when running `phpunit`
BuddyPress unit testing will conflict with stand alone bbPress user testing, when BuddyPress is active the core members component cannot be deactivated thus testing users with BuddyPress at `/member/username` vs bbPress only `/user/username` and custom rewrites `/custom-user-slug/username` will cause conflicts in user PHPUnit tests.
A new Grunt sub task `grunt phpunit:buddypress` has been added to test BuddyPress integration with bbPress without compromising bbPress standalone PHPUnit testing.
Props netweb. See #2782
|
[3247]
|
johnjamesjacoby
|
Exclude forums, topics, and replies from site wide post and page search.
We have our own search queries for each post type, and it's not currently possible to adjust the look of individual search results on the fly via theme compatibility.
|
[5290]
|
johnjamesjacoby
|
Experiment with `grunt-pot`:
* Add `grunt-pot` to `package.json`
* Adds grunt task `pot` to `grunt build` and `grunt build-release`
* Creates `bbpress.pot` in `/build` & removes `bbpress.pot` from `/src`
* Checks for the following keywords: `__`, `_e`, `_x`, `_n`, `_ex`, `_nx`, `esc_attr__`, `esc_attr_e`, `esc_attr_x`, `esc_html__`, `esc_html_e`, `esc_html_x`, `_nx_noop`
* Props netweb. See #2542.
|
[6180]
|
johnjamesjacoby
|
Extend: Consolidate some BuddyPress hooks to the top of each file.
|
[6172]
|
johnjamesjacoby
|
Extend: Fix a typo in docs.
|
[4395]
|
johnjamesjacoby
|
Extensions:
* Introduce core/extend.php to assist in loading extentions in a more common way.
* Move some !BuddyPress code around, into the files it makes the most sense for it to be in.
* Remove some redundant !BuddyPress loader code.
|
[4489]
|
johnjamesjacoby
|
Extract:
* Brackets in bbp_update_forum_reply_count().
|
[4508]
|
johnjamesjacoby
|
Extract:
* Clean up bbp_parse_args() usages and inline documents.
* Fixes #2056.
|
[4480]
|
johnjamesjacoby
|
Extract:
* Remove extract() calls from some statistics functions.
* See #2056.
|
[4499]
|
johnjamesjacoby
|
Extract:
* Remove extract() from bbp_check_for_duplicate().
* Improve code in bbp_check_for_duplicate() to support this.
* See #2056.
|
[4487]
|
johnjamesjacoby
|
Extract:
* Remove extract() from bbp_create_initial_content().
* See #2056.
|
[4481]
|
johnjamesjacoby
|
Extract:
* Remove extract() from bbp_filter_anonymous_post_data().
* See #2056.
|
[4483]
|
johnjamesjacoby
|
Extract:
* Remove extract() from bbp_get_breadcrumb().
* Other general code cleanup.
* See #2056.
|
[4485]
|
johnjamesjacoby
|
Extract:
* Remove extract() from bbp_get_dropdown().
* Other general code cleanup.
* See #2056.
|
[4502]
|
johnjamesjacoby
|
Extract:
* Remove extract() from bbp_get_single_forum_description().
* See #2056.
|
[4484]
|
johnjamesjacoby
|
Extract:
* Remove extract() from bbp_get_the_content().
* Other general code cleanup.
* See #2056.
|
[4503]
|
johnjamesjacoby
|
Extract:
* Remove extract() from bbp_list_forums().
* See #2056.
|
[4488]
|
johnjamesjacoby
|
Extract:
* Remove extract() from bbp_update_forum().
* See #2056.
|
[4486]
|
johnjamesjacoby
|
Extract:
* Remove extract() from bbp_update_reply_revision_log().
* Other general code cleanup.
* See #2056.
|
[4490]
|
johnjamesjacoby
|
Extract:
* Remove extract() from bbp_update_topic_revision_log().
* See #2056.
|
[4482]
|
johnjamesjacoby
|
Extract:
* Remove extract() from bbp_wp_login_action().
* See #2056.
|
[4497]
|
johnjamesjacoby
|
Extract:
* Remove extract() from extra statistics page template.
* See #2056.
|
[4493]
|
johnjamesjacoby
|
Extract:
* Remove extract() from widgets.
* See #2056.
|
[4507]
|
johnjamesjacoby
|
Extract:
* Remove extract() usages from /replies/template-tags.php.
* See #2056.
|
[4506]
|
johnjamesjacoby
|
Extract:
* Remove extract() usages from /topics/template-tags.php.
* See #2056.
|
[4498]
|
johnjamesjacoby
|
Extract:
* Remove extract() usages from /users/template-tag.php.
* See #2056.
|
[4501]
|
johnjamesjacoby
|
Extract:
* Remove unused BBP_Forum_Walker class, and bbp_walk_forum function, that use extract().
* See #2056.
|
[3415]
|
johnjamesjacoby
|
Extrea duplicate admin menu separator prevention.
|
[3648]
|
johnjamesjacoby
|
Fall back on user_login, and lastly "Anonymous" if no name is found anywhere. Fixes #1704.
|
[5054]
|
johnjamesjacoby
|
Fallback to 'title' sorting in bbp_list_forums() for subforum sorting. Hat tip mordauk. Fixes #2373.
|
[5058]
|
johnjamesjacoby
|
Fallback to title sorting in bbp_has_forums() if no menu_order is present. Props netweb. Fixes #2373.
|
[6493]
|
johnjamesjacoby
|
Favorites/Subscriptions improvements:
* Remove superfluous checks against current current user fav/sub status
* Always return `$success`
* Prefer `bbp_get_` functions over generic `intval()` to validate `$_GET` ID's
|
[6109]
|
johnjamesjacoby
|
Favorites/Subscriptions/Moderators: Introduce metadata API for linking multiple users to multiple forums/topics.
Previous to this, connections were stored in `usermeta`. We knew this would not scale, but bbPress 1 had a friendlier database schema & we expected WordPress's taxonomy/relationship roadmap would be farther along by now.
By storing user ID's in `postmeta` instead, we gain an ability to query for connections from both directions without custom MySQL, while also leveraging persistent caching in a more sane way.
This commit includes several new helper functions for low-level relationship management, as well as modifications to existing functions to allow them to continue to work as they always have.
See: #2959.
|
[6307]
|
johnjamesjacoby
|
Favorites/Subscriptions: Add `redirect_to` parameters to links if viewing relevant user profile pages.
See #3065.
|
[6308]
|
johnjamesjacoby
|
Favorites/Subscriptions: Add paged data to permalinks when in the loop.
Also add`redirect_to` parameters to links if passed in.
Fixes #3065.
|
[6305]
|
johnjamesjacoby
|
Favorites/Subscriptions: Look for a `redirect_to` destination in handlers.
See #3065.
|
[6309]
|
johnjamesjacoby
|
Favorites/Subscriptions: Pagination & `redirect_to` clean-up.
* PHPDoc & inline doc
* Prefer `urlencode()` over `esc_url()` for `redirect_to` query argument
* Corrections to forum & topic subscription loop logic, since they're both listed on the same page
See #3065.
|
[5926]
|
johnjamesjacoby
|
Favorites: Purge cache when adding/removing a favorite.
This changeset fixes a bug where cache was not busted, causing incorrect results to be returned & displayed.
Props thebrandonallen. See #2855.
|
[3978]
|
johnjamesjacoby
|
Favorities:
* Add $topic_id param to bbp_user_favorites_link() to allow overriding link.
* Check reply post-type, and use topic ID if link is displayed there.
|
[3435]
|
johnjamesjacoby
|
Feed me 2.0! Improvements to feeds, allowing to filter by topic, reply, and defaulting to all. Works with single forums, topics, and their related content.
|
[3974]
|
johnjamesjacoby
|
Feeds:
* Add 'feed' query-var to bbp_request_feed_trap() queries.
|
[3975]
|
johnjamesjacoby
|
Feeds:
* Do not append topic and reply revision information to feeds.
|
[4267]
|
johnjamesjacoby
|
Feeds:
* Fix feed generation time for topics and replies.
* Fixes #1993.
* Props SteveAtty.
|
[3976]
|
johnjamesjacoby
|
Feeds:
* Never separate the lead topic when viewing a feed.
* Add is_feed() check to bbp_show_lead_topic().
|
[3973]
|
johnjamesjacoby
|
Feeds:
* Use query_posts() in bbp_request_feed_trap().
* Provides example on potential use-case in bbPress core.
* Removes need to reference $wp_query global directly.
|
[6304]
|
johnjamesjacoby
|
Feeds: Allow feed titles to be filtered (using the WordPress filter name.)
Also removes redundant conditional in replies feed.
Props SergeyBiryukov. Fixes #3064.
|
[6224]
|
johnjamesjacoby
|
Feeds: Avoid duplicate site name in replies feed title.
Fixes #2998. Props SergeyBiryukov.
|
[6306]
|
johnjamesjacoby
|
Feeds: Call `get_wp_title_rss()` in replies feeds.
See #3064. Missed in r6304.
|
[6318]
|
johnjamesjacoby
|
Feeds: Run for it, Marty!
Props thebrandonallen. Fixes #3066.
|
[6794]
|
johnjamesjacoby
|
Feeds: bring back accidentally deleted semi-colon from r6793.
|
[6793]
|
johnjamesjacoby
|
Feeds: use `esc_url_raw()` in topics & replies generator URLs.
This brings generator tag handling up to par with recent WordPress changes.
|
[2560]
|
johnjamesjacoby
|
Fill in single-bbp_reply template file
|
[2559]
|
johnjamesjacoby
|
Fill in some blanks on taxonomy-bbp_topic_tag template file
|
[3803]
|
johnjamesjacoby
|
Filter forum/topic/reply URLs and canonicalize to group forum URL if applicable:
* Fixes #1781
* Props boonebgorges
|
[3721]
|
johnjamesjacoby
|
Filter links to user subscriptions and favorites, and return them to their BuddyPress profile equivalents. See #1669.
|
[4606]
|
johnjamesjacoby
|
Filter the TeenyMCE buttons to remove buttons that users cannot use. Maybe allow images; commented out for now.
|
[4607]
|
johnjamesjacoby
|
Filter the TinyMCE quicktags buttons to remove buttons that users cannot use.
|
[4689]
|
johnjamesjacoby
|
Filter topic and reply content code trick and encoding before priority 10. Fixes third party plugin compat when filtering content. Hattip mordauk.
|
[6487]
|
johnjamesjacoby
|
Filters: Pass original `$args` array into various filters.
These were all unintentionally omitted when these filters were introduced.
|