# Discourse 2.2.0.beta9 发布说明

**URL:** https://meta.discourse.org/t/discourse-2-2-0-beta9-release-notes/107112
**Category:** Announcements
**Tags:** release-notes
**Created:** [2019年一月21日 19:58 UTC](https://meta.discourse.org/t/discourse-2-2-0-beta9-release-notes/107112 "2019-01-21T19:58:53Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![jomaxro](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jomaxro/32/126216_2.png) [@jomaxro](https://meta.discourse.org/u/jomaxro)
#### Post date: [2019年一月21日 19:58 UTC](https://meta.discourse.org/t/discourse-2-2-0-beta9-release-notes/107112/1 "2019-01-21T19:58:53Z")

</div>

# New features in 2.2.0.beta9

### New Consolidated Pageview Chart

Ever wonder how many of your pageviews came from crawlers? What about anonymous users versus logged in? Replacing the old table based data from the old dashboard is a brand new stacked column graph for quick at a glance data. Need specifics, hover over a specific date to see the exact pageview count from each source.

 ![image](https://global.discourse-cdn.com/meta/original/3X/3/1/3179838c953dc9aeaf5d08f4e68a4c3392cb7101.png)

### Content Security Policy (CSP) is now default on for new sites

CSP, a security policy which helps mitigate Cross Site Scripting (XSS) attacks was first added to Discourse back in [beta6](https://meta.discourse.org/t/discourse-2-2-0-beta6-release-notes/104280). As of this beta, CSP will be enabled by default for all new sites. For all the details, including how to configure your policy if you use ads or other external scripts, see

> [@Mitigate XSS Attacks with Content Security Policy](https://meta.discourse.org/t/mitigate-xss-attacks-with-content-security-policy/104243):
>
> bookmark This guide explains how to use Content Security Policy (CSP) to mitigate Cross-Site Scripting (XSS) attacks in Discourse. It covers CSP basics, configuration, and best practices. person_raising_hand Required user level: Administrator Summary Content Security Policy (CSP) is a crucial security feature in Discourse that helps protect against Cross-Site Scripting (XSS) and other injection attacks. This guide covers the basics of CSP, how it’s implemented in Discourse, and how to c…

### Consolidate like notifications

Does your site have that one user that likes every single post? The one who causes your notifications to overflow when you wake up in the morning? Good news! Discourse now merges sequential likes from the same user, helping keep your notification history happy. By default, sequential likes will be merged if there are 5 or more, and they happen within 2 hours of each other. This can be configured via the `likes_notification_consolidation_threshold` and `likes_notification_consolidation_window_mins ` site settings.

 ![image](https://global.discourse-cdn.com/meta/original/3X/7/6/7674fced5df16460ba8a5a43aac06634756e5129.png) ![image](https://global.discourse-cdn.com/meta/original/3X/0/f/0f36fdaf33ae818704cba92b851aaeb2dfb584c0.png)

### User Deletion Improvements

Deleting a user is generally a “last resort” action taken on a site. Not only is it completely irreversible, it also can break topics where the user participated, as their posts are all removed as well. For that reason alone, we strongly recommend anonymizing users to remove all their personal info, while keeping their posts (no longer associated with them) in tact. When a long-time user does need to be deleted, it can fail as there is so much data associated with the user. We’ve made a number of changes to improve the performance of long-time user deletion. If you have issues deleting a long-time user even after deleting all their posts, please let us know in #Support.

### Support for localized themes

Themes are a powerful way to customize the look and feel of your Discourse site. Some themes go beyond layout and color changes, and add new buttons, or other elements that include text. Discourse now supports localized themes, so you can create your theme once and have it work in all the languages you translate it to. For more details, check out [FEATURE: Support for localized themes (#6848) · discourse/discourse@880311d · GitHub](https://github.com/discourse/discourse/commit/880311dd4d2b367e54cc8244fba60fce69e121c3), and keep and eye open for a topic here on Meta with more details soon.

---

<div class="post-metadata">

### Author: ![jomaxro](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jomaxro/32/126216_2.png) [@jomaxro](https://meta.discourse.org/u/jomaxro)
#### Post date: [2019年一月21日 19:58 UTC](https://meta.discourse.org/t/discourse-2-2-0-beta9-release-notes/107112/2 "2019-01-21T19:58:53Z")

</div>

### Even more!

But wait, there’s more! We do our best to highlight new features and changes for you, but there’s always too many changes to detail. For a full list of new features, bug fixes, UX improvements, and more, be sure to review the Additional Features and Fixes listed below.

### Security Updates

This beta includes 1 security fix for issues reported by our community and [HackerOne](https://hackerone.com/discourse).

- Fix possible XSS with badges

# Plugin improvements

### Intercom

Initial release. See [Discourse Intercom (Advanced)](https://meta.discourse.org/t/discourse-intercom/106622) for details

### Yearly Review

- Allow the review topic to be published up until the end of Jan 2019
- Bug fix

### [WP Discourse](https://github.com/discourse/wp-discourse)

- Support overriding publishing username
- Support publishing topic as unlisted
- Bug fixes

# Additional Features and Fixes

> **Click to expand**
>
> ### New Features
> 
> - Introduce ultra\_low priority queue
> - Allow calling user destroyer without a transaction
> 
> ### Bug Fixes
> 
> - IE11 layout glitches
> - Don’t override user flair styles in topic map
> - Better legend labels for stacked-charts
> - Incorrect subscription in `PostgreSQLFallbackHandler`.
> - `ForumsController` doesn’t need to inherit from `ApplicationController`.
> - Don’t update `User#last_seen_at` when PG is readonly take 2.
> - Don’t update `User#last_seen_at` when PG is in readonly.
> - Avoid throwing an error when processing PG down message.
> - Don’t log request when Discourse is in readonly due to PG.
> - Use ENV values instead of ‘S3Helper.s3\_options’ in migrate\_to\_s3
> - Changing owner of small action post failed
> - Update about/license URLs when updating theme from remote source
> - Ensures visits reports are correcttly differencing mobile/all
> - PostLabel was not working for totals
> - Remove full quotes only from new posts.
> - Correct deprecated theme settings in handlebars templates
> - Correctly import theme assets with spaces in filename
> - Mods weren’t able to see emails in admin user list
> - Keep original subject in emails to staged users
> - Since Ember 3 interceptClick was not working on buffered links
> - Remove old reference and use `MiniScheduler::Stat`.
> - Text logo does not show up on non ember pages.
> - Refresh “/categories” on logo click
> - Refresh discovery categories on logo click
> - Use ordered\_posts for last post check, not the posts relation
> - Do not hide posts automatically when flagged by staff user
> - Navigate to full page search when enter key used in topic
> - Wrap theme javascript inside IIFE to prevent using global namespace
> - Theme settings are referenced in JS by `settings`, not `themeSetting`
> - Regression lead to a 404 when trying to filter user posts
> - Avoid rescuing error in login hint initializer.
> - Liked notification consolidation has to account for user like frequency setting.
> - Improve rake emails:test task
> - Rake emails:test to bypass the “STARTTLS required” message
> - Too much j
> - Properly clean out post and user actions on destroy user
> - Sort topics/posts/links in descending order in user summaries
> - Heisentest
> - `Ember.warn` needs an `id`
> - Makes click-interceptor working with touchstart
> - Makes whisper state more resilient
> - Only add the trust level name for numeric trust levels
> - Add watching\_first\_post to NOTIFIABLE\_TYPES
> - Tweaking topic footer dropdowns
> - Use GlobalSetting values instead of ENV variables in migrate\_to\_s3
> - Don’t show liked consolidated notification when frequency is never.
> - Allow liked notifications consolidation to be disabled.
> - Consolidated like notifications links to wrong user on user page.
> - Liked notifications should not be consolidated across multiple users.
> - Profile picture not showing up on user admin page
> - Refresh topic list on logo click
> - Prevent layout changes while images are lazy-loading
> - Tooltip for unlisted topics wasn’t shown in topic list
> - Prefix should precede folder path (follow-up on 10fbb07e)
> - Call method only if it exists
> - Include folder name in prefix for listing files on S3 (follow-up on 3ec38f5a)
> 
> ### UX Changes
> 
> - Invert pikaday png for dark themes
> - We don’t have bulk select on mobile, so we should hide the button
> - Improve button alignment, fix invite header
> - Improve alignment of new post badge on mobile
> - Correct innacurate descriptions for short\_title, pwa\_config\_title\_warning
> - Remove unused translations
> - Improving user stream alignment and spacing
> - Badge alignment adjustments
> - Bump up base font size 1px, add smaller text size option
> - Improve short\_title SiteSetting description
> - Improve logo setting texts to hint that dimensions are a requirement
> - Normalize all SiteSetting text dimensions to use the ‘512 × 512’ format
> - Larger/Largest font-sizes should be 1px larger on mobile
> - Soften dashboard warning PM
> - Soften the “problems” alert on dashboard
> - Improves dates display in emails
> - Sort admins and moderators by last seen date on /about page
> - Only show active admins and moderators on /about page
> 
> ### Performance
> 
> - Delete potentially large associated tables before user\_destroyer.destroy transaction
> - Bulk feature topic users & reset topic counters after an import
> - Delete user and post actions vs destroy on user destroy
