mirror of
https://github.com/irislib/iris-messenger.git
synced 2024-10-19 06:33:32 +00:00
autologin fix
This commit is contained in:
parent
809f1d9633
commit
b71f38ce17
@ -1,8 +1,7 @@
|
||||
import { Helmet } from 'react-helmet';
|
||||
import { createHashHistory } from 'history';
|
||||
import iris from 'iris-lib';
|
||||
import AsyncRoute from 'preact-async-route';
|
||||
import { CustomHistory, Router, RouterOnChangeArgs } from 'preact-router';
|
||||
import { Router, RouterOnChangeArgs } from 'preact-router';
|
||||
|
||||
import '@fontsource/lato';
|
||||
|
||||
@ -47,7 +46,7 @@ type ReactState = {
|
||||
};
|
||||
|
||||
// need to add initChannels: true to here and login() to get channels to load. disabled to test performance
|
||||
iris.session.init({ autologin: window.location.hash.length > 2, autofollow: false });
|
||||
iris.session.init({ autologin: window.location.href.length > 1, autofollow: false });
|
||||
Nostr.init();
|
||||
|
||||
class Main extends Component<Props, ReactState> {
|
||||
|
@ -78,10 +78,7 @@ class Footer extends Component<Props, State> {
|
||||
<a href="/global" class={`btn ${activeRoute === '/global' ? 'active' : ''}`}>
|
||||
{Icons.global}
|
||||
</a>
|
||||
<a
|
||||
href={`/${key}`}
|
||||
class={`${activeRoute === `/${key}` ? 'active' : ''} my-profile`}
|
||||
>
|
||||
<a href={`/${key}`} class={`${activeRoute === `/${key}` ? 'active' : ''} my-profile`}>
|
||||
<Identicon str={key} width={34} />
|
||||
</a>
|
||||
</div>
|
||||
|
@ -216,7 +216,7 @@ class Login extends Component {
|
||||
<div id="existing-account-login">
|
||||
<p>
|
||||
<a href="#" id="show-create-account" onClick={(e) => this.showCreateAccount(e)}>
|
||||
{t('back')}
|
||||
{t('back')}
|
||||
</a>
|
||||
</p>
|
||||
{this.renderExistingAccountLogin()}
|
||||
|
Loading…
Reference in New Issue
Block a user