2021-12-28 · 7 🎉 · 5 🚀 · 26 🐛 · 37 🔍 · 28 👩💻👨💻
Engine versions
- Node:
12.22.1
- NPM:
6.14.1
- MongoDB:
3.6, 4.0, 4.2, 4.4, 5.0
- Apps-Engine:
1.29.0
🎉 New features
-
APPS: Add new email event for apps (#23925)
Introduces a new event called before an email is sent by the Mailer. Apps can intercept and modify the email that will be sent, or even prevent it from being sent altogether. For more details, check https://github.com/RocketChat/Rocket.Chat.Apps-engine/pull/461/files#diff-301e8a58164edbf315da2a43c4923f153dbc909573de1e60aa9f730f7488ac82
-
APPS: Allow apps to open contextual bar (#23843)
Opens a contextual bar using app ui interactions (
CONTEXTUAL_BAR_OPEN
)Rocket-Chat.mp4
-
APPS: Allow Rocket.Chat Apps to register custom action buttons (#23679)
Add an action button manager that allows apps to register custom action buttons that trigger interaction callbacks in them
-
APPS: getUserUnreadMessageCount Bridge (#23972)
-
APPS: Possibility to set room closer via Apps LivechatBridge.closeRoom (#21025)
Add an optional param named
closer
intoLivechatBridge.closeRoom
so that it will be possible to close the room and send a close room message with the correct room closer.
If the param is not passed, use the room visitor as the room closer. -
EE: Introduce fallback department support (#23939)
-
Show Omnichannel room icon based on source definition (#23912)
🚀 Improvements
-
Allow e-mail channel to be used without default department. (#23945)
Due to a missing condition in the e-mail input processing, Rocket.Chat was unable to receive e-mails from e-mail channels that did not have a default department.
-
Omnichannel Visitor Endpoints error handling (#23819)
-
Replace SortListItem and CreateListItem with ListItem (#24007)
-
Update "Message Erasure Type" setting's description (#23879)
-
Improves the "Message Erasure Type" setting's description by providing more details regarding the expected behavior of each option ("Keep Messages and User Name", "Delete All Messages" and "Remove link between user and messages");
-
Remove outdated translations (for this setting's description).
-
-
Webdav methods sanitization (#23924)
The improvement modify
server_url
anduser_id
params intoserverURL
anduserId
more suitable to our camelCase pattern. Also converts the webdav methods into .ts helping us to prevent issues in the next modal rewrites efforts.
🐛 Bug fixes
-
Add CSP to authorize auto-close of CAS login window (#23215 by @goyome)
Add the hash of the JS inside the page that won't close ( window.close(); )
-
Add missing .png to clipboard uploaded file name (#23833)
-
broken
Word Placement Anywhere
andRun on edits
toggles in integration page (#23901 by @aswinidev) -
Broken links present in some languages (#23987 by @aswinidev)
-
Changes on department agents should mark form as dirty (#19640 by @rafaelblink)
-
Custom emoji route in admin (#23882 by @sidmohanty11)
fix-custom-emoji.mp4
-
Custom status doesn't update properly (#23860)
-
DMs being created with username instead of user's name (#23848)
-
Email notifications settings not being honored on new DMs (#23574)
-
Error when creating an inactive user in admin panel (#23859)
- Fix
usersInRole
array used to send email to activate a user.
- Fix
-
Fix no message size limit for method sendMessageLivechat (#23558)
-
Headers already sent error when user data download is disabled (#23805)
When using the export message tool when trying to download the file using the link sent via email if the feature "Export User Data" is disabled an error was being thrown causing the request to halt.
This is the error shown in the logs:
=== UnHandledPromiseRejection === Error [ERR_HTTP_HEADERS_SENT] [ERR_HTTP_HEADERS_SENT]: Cannot set headers after they are sent to the client at ServerResponse.setHeader (_http_outgoing.js:530:11) at ServerResponse.res.setHeader (/app/bundle/programs/server/npm/node_modules/meteor/simple_json-routes/node_modules/connect/lib/patch.js:134:22) at app/user-data-download/server/exportDownload.js:14:7 at /app/bundle/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/fiber_pool.js:43:40 { code: 'ERR_HTTP_HEADERS_SENT' } --------------------------------- Errors like this can cause oplog processing errors. Setting EXIT_UNHANDLEDPROMISEREJECTION will cause the process to exit allowing your service to automatically restart the process Future node.js versions will automatically exit the process =================================
-
Jitsi call already ended (#23904 by @Aman-Maheshwari & @yash-rajpal)
- Fix Jitsi timeout update -- which caused the "Jitsi call already ended" error when trying to join a call some time after its creation;
-
LDAP Sync doing nothing when set to only import new users. (#23823)
-
Missing custom user status ellipsis (#23831)
before
after
-
Missing edit icon in sequential thread messages (#23948)
before
after
-
Modal keeps state if reset too fast. (#23791)
Queued updates so the Modal has a chance to close.
Used a random key to ensure modal doesn't keep it's state. -
OTR not working (#23973)
A rule on the user notification streamer was changed recently, and the check for writing on the streamer was wrong. Changed it to allow all logged users.
-
Popover position for arabic languages (#23888 by @yash-rajpal)
-
Removing Edit message from messageBox on room changed (#23910 by @yash-rajpal)
Removing edit message from messageBox and local storage on messageBox destroyed.
-
Segmentation fault on CentOS 7 due to outdated
sharp
(#23796)Upgrades
sharp
to avoid a segmentation fault on CentOS 7 during startup related tosharp.node
being loaded viaprocess.dlopen()
.Suggested as a fix for versions
4.0.x
and4.1.x
. -
teams.leave client usage (#23959)
-
teams.removeMembers client usage (#23857)
-
Translations for App Select Settings not working (#23908)
Derived from PR #19238
-
Wrong button for non trial apps (#23861)
This PR solves a bug on the marketplace that was happening with WhatsApp where it was displaying a trial button even though it didn't have a free trial period. The new verification I've added checks if the app is subscription-based and then checks if it has 0 trial days in all of its tiers. If it does, it shows a subscribe button. If it doesn't, it displays a trial button. Also, I've exposed the itsEnterpriseOnly flag as an extra measure in the case of apps like Facebook Messenger that are enterprise-only and consequently should show the subscribe button.
Before:
After:
🔍 Minor changes
-
Bump @rocket.chat/string-helpers from 0.29.0 to 0.30.1 in /ee/server/services (#23526 by @dependabot[bot])
-
Bump cookie-parser from 1.4.5 to 1.4.6 in /ee/server/services (#23921 by @dependabot[bot])
-
Bump mailparser from 3.2.0 to 3.4.0 (#23466 by @dependabot[bot])
-
Bump path-parse from 1.0.6 to 1.0.7 (#23689 by @dependabot[bot])
-
Bump pm2 from 5.1.1 to 5.1.2 in /ee/server/services (#23289 by @dependabot[bot])
-
Bump thehanimo/pr-title-checker from 1.2 to 1.3.4 (#23853 by @dependabot[bot])
-
Chore: added last login to users.list (#23846)
-
Chore: Bump fuselage 0.31.0 (#24046)
-
Chore: Centralize email validation functionality (#23816)
-
Create lib for validating emails
-
Modify places that validate emails to use the new central function
-
-
Chore: Change Menu props to accept next fuselage version (#23839)
-
Chore: Create script to add new migrations (#23822)
-
Create NPM script to add new migrations
-
TODO: Infer next migration number from file list
-
-
Chore: Deleted LivechatPageVisited (#23993)
-
Chore: Enable prefer-optional-chain ESLint rule for TypeScript files (#23786)
Code is bad. It rots. It requires periodic maintenance. It has bugs that need to be found. New features mean old code has to be adapted.
The more code you have, the more places there are for bugs to hide. The longer checkouts or compiles take. The longer it takes a new employee to make sense of your system. If you have to refactor there's more stuff to move around.
Furthermore, more code often means less flexibility and functionality. This is counter-intuitive, but a lot of times a simple, elegant solution is faster and more general than the plodding mess of code produced by a programmer of lesser talent.
Code is produced by engineers. To make more code requires more engineers. Engineers have n^2 communication costs, and all that code they add to the system, while expanding its capability, also increases a whole basket of costs.
You should do whatever possible to increase the productivity of individual programmers in terms of the expressive power of the code they write. Less code to do the same thing (and possibly better). Less programmers to hire. Less organizational communication costs.— [Rich Skrenta][1]
Mixing two problem domains in code is prone to errors. In this small example
declare const y: { z: unknown } | undefined; const x = y && y.z;
we're (1) checking the nullity of
y
and (2) attributingy.z
tox
, where (2) is clearly the main problem we're solving with code. The optional chaining is a good technique to handle nullity as a mere implementation detail:declare const y: { z: unknown } | undefined; const x = y?.z;
Attributing
y.z
tox
is more easily readable than the nullity check ofy
.This PR aims to add
@typescript-eslint/prefer-optional-chain
rule to ESlint configuration at warning level. -
Chore: Fix hasRole warning (#23914)
-
Chore: Remove the
mobile-download-file
permission (#23996)- Remove the
mobile-download-file
permission and its descriptions.
- Remove the
-
Chore: Replace new typography (#23756)
-
Chore: Replace typography (#24021)
-
Chore: Update Apps-Engine to latest (#24045)
-
Chore: update docker image base to latest node 12 patch (#23875)
-
Chore: Update Livechat (#23913)
-
Chore: Update pino deps (#23922)
-
Chore: Use only LivechatTriggerRaw model (#23974)
-
i18n: Language update from LingoHub 🤖 on 2021-12-06Z (#23873)
-
i18n: Language update from LingoHub 🤖 on 2021-12-13Z (#23930)
-
i18n: Language update from LingoHub 🤖 on 2021-12-20Z (#23991)
-
i18n: Language update from LingoHub 🤖 on 2021-12-27Z (#24030)
-
Merge master into develop & Set version to 4.3.0-develop (#23827)
-
Regression: Add migration for omni rooms with no source (#24012)
Add a migration to add source property to all the omnichannel rooms which don't have it yet. All these rooms will have source type as
other
-
Regression: Add optional chaining to possibly undefined fields (#24033)
-
Regression: addAction verification breaking rooms (#24019)
-
Regression: Ensure room action buttons only appear inside menu (#24035)
Currently, action buttons registered by apps to appear in the ROOM_ACTION context show in the first position of the list, but since they don't have an icon they are effectively invisible in the tab bar.
Here we change the order configuration of the button so we make sure it only shows inside the room menu
-
Regression: Fix omnichannel empty source usage (#24008)
-
Regression: Let Meteor.absoluteUrl.defaultOptions.rootUrl as baseURI (#24009)
-
Regression: Missing padding in popover with custom template (#23877)
-
Regression: Remove dangling console.log (#24034)
A empty array have been printed to console due to a promise chained to
console.log
andconsole.error
calls, probably for debugging purposes. -
Regression: Remove self from fallback departments dropdown (#24018)
-
Regression: Toolbox render item (#23862)
👩💻👨💻 Contributors 😍
- @Aman-Maheshwari
- @aswinidev
- @cuonghuunguyen
- @dependabot[bot]
- @goyome
- @qwertiko
- @rafaelblink
- @sidmohanty11
- @yash-rajpal