aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorHJ <30-hj@users.noreply.git.pleroma.social>2022-04-10 06:32:41 +0000
committerHJ <30-hj@users.noreply.git.pleroma.social>2022-04-10 06:32:41 +0000
commit4d15cbcbbd4b47fb37704f1408e5b8e6d9840758 (patch)
tree9b70c30db4766be79cf1d5e222f4448847163ab3 /src
parent87311cff09fb19978a050b468a59126c4d13fd2f (diff)
parent3b02566e16d33956604815e4bd5190f8f8144253 (diff)
Merge branch 'from/develop/tusooa/1158-hidden-tabs' into 'develop'
Fix tab switcher not working when some tabs hidden Closes #1158 See merge request pleroma/pleroma-fe!1511
Diffstat (limited to 'src')
-rw-r--r--src/components/tab_switcher/tab_switcher.jsx2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/components/tab_switcher/tab_switcher.jsx b/src/components/tab_switcher/tab_switcher.jsx
index f5a1e603..c8d390bc 100644
--- a/src/components/tab_switcher/tab_switcher.jsx
+++ b/src/components/tab_switcher/tab_switcher.jsx
@@ -50,7 +50,7 @@ export default {
activeIndex () {
// In case of controlled component
if (this.activeTab) {
- return this.slots().findIndex(slot => this.activeTab === slot.props.key)
+ return this.slots().findIndex(slot => slot && slot.props && this.activeTab === slot.props.key)
} else {
return this.active
}