mirror of
https://github.com/discourse/discourse.git
synced 2025-02-26 06:43:10 +08:00
correct logic
This commit is contained in:
parent
6dc8dda7b6
commit
b4d7ff1dac
@ -41,7 +41,9 @@ export default Em.Controller.extend({
|
|||||||
const searchContext = this.get('searchContext');
|
const searchContext = this.get('searchContext');
|
||||||
|
|
||||||
if (this.get('searchContextEnabled')) {
|
if (this.get('searchContextEnabled')) {
|
||||||
if (searchContext.id.toLowerCase() === this.get('currentUser.username_lower')) {
|
if (searchContext.id.toLowerCase() === this.get('currentUser.username_lower') &&
|
||||||
|
searchContext.type === "private_messages"
|
||||||
|
) {
|
||||||
url += ' in:private';
|
url += ' in:private';
|
||||||
} else {
|
} else {
|
||||||
url += encodeURIComponent(" " + searchContext.type + ":" + searchContext.id);
|
url += encodeURIComponent(" " + searchContext.type + ":" + searchContext.id);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user