Skip to content

Commit

Permalink
refactor(item): rename DateTime JSON fields
Browse files Browse the repository at this point in the history
  • Loading branch information
albertms10 committed Dec 4, 2022
1 parent 214c7c0 commit 396d105
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions lib/src/model/item.dart
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import 'serializable.dart';

abstract class _JsonFields {
static const id = 'id';
static const creationDateTime = 'cdt';
static const modificationDateTime = 'mdt';
static const creationDateTime = 'cd';
static const modificationDateTime = 'md';
static const modificationCount = 'mc';
}

Expand Down
8 changes: 4 additions & 4 deletions test/model/cabin/cabin_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ void main() {
test('should create a new Cabin from a JSON object', () {
const rawCabin = {
'id': 'cabin-id',
'cdt': '1969-07-20T20:18:04.000Z',
'mdt': '1969-07-20T20:18:04.000Z',
'cd': '1969-07-20T20:18:04.000Z',
'md': '1969-07-20T20:18:04.000Z',
'mc': 1,
'n': 1,
'e': {
Expand Down Expand Up @@ -47,8 +47,8 @@ void main() {
() {
final rawCabin = {
'id': 'cabin-id',
'cdt': '1969-07-20T20:18:04.000Z',
'mdt': '1969-07-20T20:18:04.000Z',
'cd': '1969-07-20T20:18:04.000Z',
'md': '1969-07-20T20:18:04.000Z',
'mc': 1,
'n': 1,
'e': {
Expand Down

0 comments on commit 396d105

Please sign in to comment.