Add log rotation to server & UI improvements #157
3 changed files with 9 additions and 5 deletions
Use original timestamps for pull events
commit
f3bc3c58d1
|
|
@ -4,7 +4,7 @@
|
||||||
background-color: var(--color-base-00);
|
background-color: var(--color-base-00);
|
||||||
|
|
|||||||
border-radius: var(--radius-l);
|
border-radius: var(--radius-l);
|
||||||
container-type: inline-size;
|
container-type: inline-size;
|
||||||
word-break: break-all;
|
word-break: break-word;
|
||||||
|
|
||||||
&.clickable {
|
&.clickable {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
|
|
||||||
|
|
@ -228,7 +228,8 @@ export class UnrestrictedSyncer {
|
||||||
},
|
},
|
||||||
message:
|
message:
|
||||||
"File has been deleted remotely, so we deleted it locally",
|
"File has been deleted remotely, so we deleted it locally",
|
||||||
author: response.userId
|
author: response.userId,
|
||||||
|
timestamp: new Date(response.updatedDate)
|
||||||
});
|
});
|
||||||
|
|
||||||
this.database.delete(document.relativePath);
|
this.database.delete(document.relativePath);
|
||||||
|
|
@ -325,7 +326,8 @@ export class UnrestrictedSyncer {
|
||||||
status: SyncStatus.SUCCESS,
|
status: SyncStatus.SUCCESS,
|
||||||
details: actualUpdateDetails,
|
details: actualUpdateDetails,
|
||||||
message: `Successfully downloaded remotely updated file from the server`,
|
message: `Successfully downloaded remotely updated file from the server`,
|
||||||
author: response.userId
|
author: response.userId,
|
||||||
|
timestamp: new Date(response.updatedDate)
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
@ -429,7 +431,8 @@ export class UnrestrictedSyncer {
|
||||||
status: SyncStatus.SUCCESS,
|
status: SyncStatus.SUCCESS,
|
||||||
details: updateDetails,
|
details: updateDetails,
|
||||||
message: `Successfully downloaded remote file which hadn't existed locally`,
|
message: `Successfully downloaded remote file which hadn't existed locally`,
|
||||||
author: remoteVersion.userId
|
author: remoteVersion.userId,
|
||||||
|
timestamp: new Date(remoteVersion.updatedDate)
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -39,6 +39,7 @@ export interface CommonHistoryEntry {
|
||||||
message: string;
|
message: string;
|
||||||
details: SyncDetails;
|
details: SyncDetails;
|
||||||
author?: string;
|
author?: string;
|
||||||
|
timestamp?: Date;
|
||||||
}
|
}
|
||||||
|
|
||||||
export enum SyncType {
|
export enum SyncType {
|
||||||
|
|
@ -92,7 +93,7 @@ export class SyncHistory {
|
||||||
public addHistoryEntry(entry: CommonHistoryEntry): void {
|
public addHistoryEntry(entry: CommonHistoryEntry): void {
|
||||||
const historyEntry = {
|
const historyEntry = {
|
||||||
...entry,
|
...entry,
|
||||||
timestamp: new Date()
|
timestamp: entry.timestamp ?? new Date()
|
||||||
};
|
};
|
||||||
|
|
||||||
const candidate = this.findSimilarRecentUpdateEntry(historyEntry);
|
const candidate = this.findSimilarRecentUpdateEntry(historyEntry);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue
Inconsistent indentation: this line uses spaces while the rest of the file uses tabs. Change to tab indentation to match the file's style.