Skip to content

Commit

Permalink
fix: изменилась модель в sites.json, теперь boolean идут с правильным…
Browse files Browse the repository at this point in the history
… типом

Из-за этого всё сломалось, т.к. было расчитано на 1 и 0
  • Loading branch information
popstas committed Jan 12, 2019
1 parent e541b23 commit 8ea385b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions store/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,8 @@ export const getters = {
// flatten site_info
for (let i in site.site_info) {
site[i] = site.site_info[i];
if (site[i] === true) site[i] = 1;
if (site[i] === false) site[i] = 0;
if (i == 'files_size') site[i] = Math.round(site[i] / 1024);
if (i == 'git_size') site[i] = Math.round(site[i] / 1024);
if (i == 'updated_time') site[i] = moment.unix(site[i]).format('YYYY-MM-DD HH:mm:ss');
Expand Down

0 comments on commit 8ea385b

Please sign in to comment.