mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-18 15:17:25 +01:00
Fix non-profile urls not being usable.
This commit is contained in:
@@ -195,10 +195,12 @@ export default {
|
|||||||
const links = this.$refs.markdownContainer.getElementsByTagName('a');
|
const links = this.$refs.markdownContainer.getElementsByTagName('a');
|
||||||
for (let i = 0; i < links.length; i++) {
|
for (let i = 0; i < links.length; i++) {
|
||||||
const link = links[i];
|
const link = links[i];
|
||||||
links[i].onclick = (ev) => {
|
if (links[i].getAttribute('href').startsWith('/profile/')) {
|
||||||
ev.preventDefault();
|
links[i].onclick = (ev) => {
|
||||||
this.$router.push({ path: link.getAttribute('href')});
|
ev.preventDefault();
|
||||||
};
|
this.$router.push({ path: link.getAttribute('href')});
|
||||||
|
};
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|||||||
Reference in New Issue
Block a user