summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMaxence Lange <maxence@artificial-owl.com>2019-10-02 15:11:46 -0100
committerGitHub <noreply@github.com>2019-10-02 15:11:46 -0100
commitc0d71b7e096b31b16c7c3446bd32bd8e059b927a (patch)
tree2cfd3e8079169bdfc5306be64d38f691fda6854f /src
parent042d51229c6129f879c8f651fa2335f991cd68a5 (diff)
parent2745fd1ed41d6bbeec1b84d7552f38b4e67ed4b9 (diff)
Merge pull request #774 from StCyr/bugfix/773/search_with_#
FIX: Removes heading '#' from the search terms as search won't work
Diffstat (limited to 'src')
-rw-r--r--src/App.vue1
-rw-r--r--src/components/Search.vue4
2 files changed, 3 insertions, 2 deletions
diff --git a/src/App.vue b/src/App.vue
index 51287119..8f9fa008 100644
--- a/src/App.vue
+++ b/src/App.vue
@@ -225,6 +225,7 @@ export default {
})
},
search(term) {
+ term = encodeURIComponent(term)
this.searchTerm = term
},
resetSearch() {
diff --git a/src/components/Search.vue b/src/components/Search.vue
index b40ca1f1..113fbf1e 100644
--- a/src/components/Search.vue
+++ b/src/components/Search.vue
@@ -28,11 +28,11 @@
{{ t('social', 'No results found') }}
</h2>
<p v-if="!loading">
- {{ t('social', 'There were no results for your search:') }} {{ term }}
+ {{ t('social', 'There were no results for your search:') }} {{ decodeURIComponent(term) }}
</p>
</div>
<div v-else>
- <h3>{{ t('social', 'Searching for') }} {{ term }}</h3>
+ <h3>{{ t('social', 'Searching for') }} {{ decodeURIComponent(term) }}</h3>
<user-entry v-for="result in allResults" :key="result.id" :item="result" />
<div v-if="hashtags.length > 0">
<li v-for="tag in hashtags" :key="tag.hashtag" class="tag">