FIX: URL to user profile in poll results. (#7315)

This commit is contained in:
Bianca Nenciu 2019-04-03 23:17:05 +03:00 committed by Régis Hanol
parent 88a46981a8
commit 3cf922a58a
2 changed files with 2 additions and 4 deletions

View File

@ -8,7 +8,6 @@ import evenRound from "discourse/plugins/poll/lib/even-round";
import { avatarFor } from "discourse/widgets/post";
import round from "discourse/lib/round";
import { relativeAge } from "discourse/lib/formatter";
import { userPath } from "discourse/lib/url";
function optionHtml(option) {
return new RawHtml({ html: `<span>${option.html}</span>` });
@ -145,7 +144,6 @@ createWidget("discourse-poll-voters", {
return h("li", [
avatarFor("tiny", {
username: user.username,
url: this.site.mobileView ? userPath(user.username) : undefined,
template: user.avatar_template
}),
" "

View File

@ -24,9 +24,9 @@ test("Public number poll", async assert => {
"it should display the right number of voters"
);
assert.ok(
assert.notOk(
find(".poll-voters:first li:first a").attr("href"),
"user URL exists"
"user URL does not exist"
);
// eslint-disable-next-line