1.19.0 Breaking Changes
-
-
-
Removals
socket.emit('admin.categories.create') removed, use
POST /api/v3/categories
socket.emit('admin.categories.purge') removed, useDELETE /api/v3/categories/:cid
socket.emit('admin.categories.update') removed, usePUT /api/v3/categories/:cid
socket.emit('admin.categories.setPrivilege') removed, usePUT /api/v3/categories/:cid/privileges/:privilege
socket.emit('admin.categories.getAll') removed, use GET/api/admin/manage/categories
socket.emit('admin.categories.getPrivilegeSettings') removed useGET /api/v3/categories/:cid/privileges
socket.emit('admin.categories.setPrivilege') removed usePUT /api/v3/categories/:cid/privileges/:privilege
socket.emit('admin.groups.create') removed use
POST /api/v3/groups
socket.emit('admin.groups.join') removed usePUT /api/v3/groups/:slug/membership/:uid
socket.emit('admin.groups.leave') removed useDELETE /api/v3/groups/:slug/membership/:uid
socket.emit('admin.groups.update') removed usePUT /api/v3/groups/:slug
socket.emit('admin.user.deleteUsers') removed use
DELETE /api/v3/users/:uid/account
socket.emit('admin.user.deleteUsersContent') removed useDELETE /api/v3/users/:uid/content
socket.emit('admin.user.deleteUsersAndContent') removed useDELETE /api/v3/users or DELETE /api/v3/users/:uid
socket.emit('admin.uploads.delete') removed use
DELETE /api/v3/files
socket.emit('posts.reply') removed use
POST /api/v3/topics/:tid
socket.emit('posts.getPost') removed userGET /api/v3/posts/:pid
socket.emit('posts.delete') removed useDELETE /api/v3/posts/:pid/state
socket.emit('posts.restore') removed usePUT /api/v3/posts/:pid/state
socket.emit('posts.purge') removed useDELETE /api/v3/posts/:pid
socket.emit('posts.getDiffs') removed use GET /api/v3/posts/:pid/diffs
socket.emit('posts.showPostAt') removed use GET /api/v3/posts/:pid/diffs/:since
socket.emit('posts.restoreDiff') removed use PUT /api/v3/posts/:pid/diffs/:since
socket.emit('posts.edit') removed usePUT /api/v3/posts/:pid
socket.emit('posts.bookmark') removed usePUT /api/v3/posts/:pid/bookmark
socket.emit('posts.unbookmark') removed useDELETE /api/v3/posts/:pid/bookmark
socket.emit('posts.movePost') removed usePUT /api/v3/posts/:pid/move
socket.emit('posts.movePosts') removed usePUT /api/v3/posts/:pid/move
socket.emit('posts.upvote') removed usePUT /api/v3/posts/:pid/vote
socket.emit('posts.downvote') removed usePUT /api/v3/posts/:pid/vote
socket.emit('posts.unvote') removed useDELETE /api/v3/posts/:pid/vote
socket.emit('topics.post') removed use
POST /api/v3/topics
socket.emit('topics.search') removed useGET /api/search
socket.emit('topics.getTopic') removed useGET /api/v3/topics/:tid
socket.emit('topics.delete') removed useDELETE /api/v3/topics/state
socket.emit('topics.restore') removed usePUT /api/v3/topics/state
socket.emit('topics.purge') removed useDELETE /api/v3/topics
socket.emit('topics.lock') removed usePUT /api/v3/topics/lock
socket.emit('topics.unlock') removed useDELETE /api/v3/topics/lock
socket.emit('topics.pin') removed usePUT /api/v3/topics/pin
socket.emit('topics.unpin') removed useDELETE /api/v3/topics/pin
socket.emit('topics.follow') removed usePUT /api/v3/topics/:tid/follow
socket.emit('topics.changeWatching') removed usePUT/DELETE /api/v3/topics/:tid/(follow|ignore)
socket.emit('groups.join') removed use
PUT /api/v3/groups/:slug/membership/:uid
socket.emit('groups.leave') removed useDELETE /api/v3/groups/:slug/membership/:uid
socket.emit('groups.grant') removed usePUT /api/v3/groups/:slug/ownership/:uid
socket.emit('groups.rescind') removed useDELETE /api/v3/groups/:slug/ownership/:uid
socket.emit('groups.update') removed usePUT /api/v3/groups/:slug
socket.emit('groups.create') removed usePOST /api/v3/groups
socket.emit('groups.delete') removed useDELETE /api/v3/groups
socket.emit('flags.create') removed use
POST /api/v3/flags
socket.emit('flags.update') removed usePUT /api/v3/flags/:flagId
socket.emit('flags.appendNote') removed usePOST /api/v3/flags/:flagId/notes
socket.emit('flags.deleteNote') removed useDELETE /api/v3/flags/:flagId/notes/:datetime
socket.emit('user.exists') removed use
HEAD /api/v3/users/bySlug/:userslug
ANDHEAD /api/v3/groups/:slug
socket.emit('user.deleteAccount') removed useDELETE /api/v3/users/:uid/account
socket.emit('user.follow') removed usePOST /api/v3/users/follow
socket.emit('user.unfollow') removed useDELETE /api/v3/users/unfollow
socket.emit('user.saveSettings') removed usePUT /api/v3/users/:uid/settings
socket.emit('user.search') removed useGET /api/users
socket.emit('user.changePicture') removed usePUT /api/v3/users/:uid/picture
socket.emit('user.changeUsernameEmail') removed usePUT /api/v3/users/:uid
socket.emit('user.updateProfile') removed usePUT /api/v3/users/:uid
socket.emit('user.changePassword') removed usePUT /api/v3/users/:uid/password
socket.emit('user.setTopicSort') removed usePUT /api/v3/users/:uid/settings
socket.emit('user.setCategorySort') removed usePUT /api/v3/users/:uid/settings
socket.emit('user.banUsers') removed usePUT /api/v3/users/:uid/ban
socket.emit('user.unbanUsers') removed useDELETE /api/v3/users/:uid/ban
socket.emit('categories.getCategory') removed use
GET /api/v3/categories/:cid
socketHelpers.setDefaultPostData removed use apiHelpers.setDefaultPostData
socketTopics.loadMoreSortedTopics
removed use infinitescroll.loadXHR
socketTopics.loadMoreFromSet
removed use infinitescroll.loadXHRDeprecations
app.alert
is deprecated usealerts.alert
fromalerts
module
app.alertError
is deprecated usealerts.error
fromalerts
module
app.alertSuccess
is deprecated usealerts.success
fromalerts
module
app.removeAlert
is deprecated usealerts.remove
fromalerts
module
app.logout
is deprecated uselogout
module directly. ierequire(['logout'], function (logout) { logout() });
app.openChat
is deprecated usechat.openChat
fromchat
module.
app.newChat
is deprecated usechat.newChat
fromchat
module.
app.enableTopicSearch
is deprecated usesearch.enableQuickSearch
fromsearch
module.
app.handleSearch
is deprecated usesearch.init
fromsearch
module.
app.prepareSearch
is deprecated usesearch.showAndFocusInput
fromsearch
module. -
Some custom themes may introduce additional navigation bars at the top of the page, above the NodeBB header menu.
Persona included code that calculated the height of the header menu and adjusted
#panel
to start just below it, but it did not account for cases where the header menu is not at the top of the page.Refactor panel padding calculation to make it simpler for themes · Issue #10023 · NodeBB/NodeBB
The panel padding calculation right now is a simple calculation of the header's height, but it needs to also take into account the header's vertical position in the viewport. Themes often add additional menus on top of the NodeBB header,...
GitHub (github.com)
Updated Persona code will do so in v1.19.0 going forward, so any custom themes that use CSS overrides to compensate will need a revisit.
-
Pages starting with
/admin/plugins
or/api/v3/admin/plugins
route prefixes no longer need to callmiddleware.admin.checkPrivileges
or do their own administrative checks. This is now automatically done.refactor: use routePrefixMap instead of routeRegexpMap, +tests by julianlam · Pull Request #10035 · NodeBB/NodeBB
Currently tests fail because privilege pages resolve if passed garbage... hmm
GitHub (github.com)
However, this could be considered breaking if you had a page with a route starting with
/admin/plugins/
, and expect to have full access to it from non-admins. -
middleware.authenticate
removed, page and API routes are now automatically authenticated via setup(Page|API)Route. Usemiddleware.authenticateRequest
(if not using route helper) andmiddleware.ensureLoggedIn
instead.middleware.authenticateOrGuest
has been renamed, usemiddleware.authenticateRequest
insteadbreaking: remove deprecated user middlewares · NodeBB/NodeBB@1a7fffc
Node.js based forum software built for the modern web - breaking: remove deprecated user middlewares · NodeBB/NodeBB@1a7fffc
GitHub (github.com)
-
-
fix: move authenticateRequest before interstitial and maintenance mod… · NodeBB/NodeBB@d89fc44
Node.js based forum software built for the modern web - fix: move authenticateRequest before interstitial and maintenance mod… · NodeBB/NodeBB@d89fc44
GitHub (github.com)
The commit associated with this issue changes the order of middlewares across all routes using setup*Route helpers.
This sounds serious, but in practice the only thing this affects is that prior to the change, all api requests using bearer token were automatically refused if the site was in maintenance mode. Now, just as admins are able to access the site during maintenance mode, admins can make bearer call authenticated API calls as well.
-
Tags allow
%
character now, themes will need to be updated to usetags.valueEncoded
instead oftags.valueEscaped
https://github.com/NodeBB/NodeBB/issues/10135See changes in persona to update your custom theme https://github.com/NodeBB/nodebb-theme-persona/commit/6aada9127865ddc1cbaf8cd5f548ebc78f7bf90a
-