You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-08 21:42:24 +03:00
Apply the user's tint once the MatrixClientPeg is moderately ready
Any earlier and we risk getting NPEs from the peg not existing. Fixes https://github.com/vector-im/riot-web/issues/6424
This commit is contained in:
@@ -26,6 +26,7 @@ import EventTimelineSet from 'matrix-js-sdk/lib/models/event-timeline-set';
|
||||
import createMatrixClient from './utils/createMatrixClient';
|
||||
import SettingsStore from './settings/SettingsStore';
|
||||
import MatrixActionCreators from './actions/MatrixActionCreators';
|
||||
import Tinter from "./Tinter";
|
||||
|
||||
interface MatrixClientCreds {
|
||||
homeserverUrl: string,
|
||||
@@ -128,6 +129,9 @@ class MatrixClientPeg {
|
||||
opts.lazyLoadMembers = true;
|
||||
}
|
||||
|
||||
const color_scheme = SettingsStore.getValue("roomColor");
|
||||
Tinter.tint(color_scheme.primary_color, color_scheme.secondary_color);
|
||||
|
||||
// Connect the matrix client to the dispatcher
|
||||
MatrixActionCreators.start(this.matrixClient);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user