mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-10 07:25:44 +01:00
Fix formatting
This commit is contained in:
@@ -27,7 +27,7 @@ type Props = WithTranslation & {
|
||||
|
||||
type State = {
|
||||
stoppableUpdateHandler?: number;
|
||||
}
|
||||
};
|
||||
|
||||
const FixedWidthTh = styled.th`
|
||||
width: 16px;
|
||||
@@ -46,7 +46,6 @@ export function findParent(path: string) {
|
||||
}
|
||||
|
||||
class FileTree extends React.Component<Props, State> {
|
||||
|
||||
constructor(props: Props) {
|
||||
super(props);
|
||||
this.state = {};
|
||||
@@ -54,10 +53,10 @@ class FileTree extends React.Component<Props, State> {
|
||||
|
||||
componentDidUpdate(prevProps: Readonly<Props>, prevState: Readonly<State>): void {
|
||||
if (prevState.stoppableUpdateHandler === this.state.stoppableUpdateHandler) {
|
||||
const {tree, updateSources} = this.props;
|
||||
const { tree, updateSources } = this.props;
|
||||
if (tree?._embedded?.children && tree._embedded.children.find(c => c.partialResult)) {
|
||||
const stoppableUpdateHandler = setTimeout(updateSources, 3000);
|
||||
this.setState({stoppableUpdateHandler: stoppableUpdateHandler});
|
||||
this.setState({ stoppableUpdateHandler: stoppableUpdateHandler });
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -177,5 +176,8 @@ const mapStateToProps = (state: any, ownProps: Props) => {
|
||||
|
||||
export default compose(
|
||||
withRouter,
|
||||
connect(mapStateToProps, mapDispatchToProps)
|
||||
connect(
|
||||
mapStateToProps,
|
||||
mapDispatchToProps
|
||||
)
|
||||
)(withTranslation("repos")(FileTree));
|
||||
|
||||
Reference in New Issue
Block a user