mirror of
https://github.com/mue/mue.git
synced 2026-06-11 19:18:57 +02:00
fix: news on overview
This commit is contained in:
@@ -106,14 +106,14 @@ export default class OrderSettings extends PureComponent {
|
||||
|
||||
async getNews() {
|
||||
const data = await (await fetch(variables.constants.API_URL + '/news')).json();
|
||||
data.news.date = new window.Date(data.news.date).toLocaleDateString(variables.languagecode.replace('_', '-'), {
|
||||
data.date = new window.Date(data.date).toLocaleDateString(variables.languagecode.replace('_', '-'), {
|
||||
year: 'numeric',
|
||||
month: 'long',
|
||||
day: 'numeric',
|
||||
});
|
||||
|
||||
this.setState({
|
||||
news: data.news,
|
||||
news: data,
|
||||
newsDone: true,
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user