mirror of
https://github.com/gosticks/web.git
synced 2026-12-03 17:51:39 +00:00
Merge pull request #51 from pi-hole/tweak/top-items-refresh-rate
Slow down updates to top lists
This commit is contained in:
@@ -25,7 +25,10 @@ class TopBlocked extends Component {
|
||||
}
|
||||
|
||||
updateChart() {
|
||||
this.updateHandler = makeCancelable(api.getTopBlocked(), { repeat: this.updateChart, interval: 10 * 1000 });
|
||||
this.updateHandler = makeCancelable(
|
||||
api.getTopBlocked(),
|
||||
{ repeat: this.updateChart, interval: 10 * 60 * 1000 }
|
||||
);
|
||||
this.updateHandler.promise.then(res => {
|
||||
this.setState({
|
||||
loading: false,
|
||||
|
||||
@@ -25,7 +25,10 @@ class TopClients extends Component {
|
||||
}
|
||||
|
||||
updateChart() {
|
||||
this.updateHandler = makeCancelable(api.getTopClients(), { repeat: this.updateChart, interval: 10 * 1000 });
|
||||
this.updateHandler = makeCancelable(
|
||||
api.getTopClients(),
|
||||
{ repeat: this.updateChart, interval: 10 * 60 * 1000 }
|
||||
);
|
||||
this.updateHandler.promise.then(res => {
|
||||
this.setState({
|
||||
loading: false,
|
||||
|
||||
@@ -25,7 +25,10 @@ class TopDomains extends Component {
|
||||
}
|
||||
|
||||
updateChart() {
|
||||
this.updateHandler = makeCancelable(api.getTopDomains(), { repeat: this.updateChart, interval: 10 * 1000 });
|
||||
this.updateHandler = makeCancelable(
|
||||
api.getTopDomains(),
|
||||
{ repeat: this.updateChart, interval: 10 * 60 * 1000 }
|
||||
);
|
||||
this.updateHandler.promise.then(res => {
|
||||
this.setState({
|
||||
loading: false,
|
||||
|
||||
Reference in New Issue
Block a user