From 95775195949bb7c092285362930eb2ca300cc780 Mon Sep 17 00:00:00 2001 From: Darin McBride Date: Tue, 24 Feb 2015 16:23:37 -0700 Subject: [PATCH] DBIC uses default_value instead of default for its defaults, update all use cases to follow the correct key. --- lib/Lacuna/DB/Result/Alliance.pm | 2 +- lib/Lacuna/DB/Result/Building.pm | 4 ++-- lib/Lacuna/DB/Result/Log/EmpireRPC.pm | 4 ++-- lib/Lacuna/DB/Result/Probes.pm | 2 +- lib/Lacuna/DB/Result/Schedule.pm | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/lib/Lacuna/DB/Result/Alliance.pm b/lib/Lacuna/DB/Result/Alliance.pm index be6436f0..2775b9ea 100644 --- a/lib/Lacuna/DB/Result/Alliance.pm +++ b/lib/Lacuna/DB/Result/Alliance.pm @@ -17,7 +17,7 @@ __PACKAGE__->add_columns( announcements => { data_type => 'text', is_nullable => 1 }, date_created => { data_type => 'datetime', is_nullable => 0, set_on_create => 1 }, stash => { data_type => 'mediumblob', is_nullable => 1, 'serializer_class' => 'JSON' }, - image => { data_type => 'varchar', size => 255, is_nullable => 0, default => 'default' }, + image => { data_type => 'varchar', size => 255, is_nullable => 0, default_value => 'default' }, ); __PACKAGE__->belongs_to('leader', 'Lacuna::DB::Result::Empire', 'leader_id', { on_delete => 'set null' }); diff --git a/lib/Lacuna/DB/Result/Building.pm b/lib/Lacuna/DB/Result/Building.pm index 2655708f..8103ac20 100755 --- a/lib/Lacuna/DB/Result/Building.pm +++ b/lib/Lacuna/DB/Result/Building.pm @@ -21,10 +21,10 @@ __PACKAGE__->add_columns( class => { data_type => 'varchar', size => 255, is_nullable => 0 }, upgrade_started => { data_type => 'datetime', is_nullable => 0, set_on_create => 1 }, upgrade_ends => { data_type => 'datetime', is_nullable => 0, set_on_create => 1 }, - is_upgrading => { data_type => 'bit', default => 0 }, + is_upgrading => { data_type => 'bit', default_value => 0 }, work_started => { data_type => 'datetime', is_nullable => 0, set_on_create => 1 }, work_ends => { data_type => 'datetime', is_nullable => 0, set_on_create => 1 }, - is_working => { data_type => 'bit', default => 0 }, + is_working => { data_type => 'bit', default_value => 0 }, work => { data_type => 'mediumblob', is_nullable => 1, 'serializer_class' => 'JSON' }, efficiency => { data_type => 'int', default_value => 100, is_nullable => 0 }, last_check => { data_type => 'datetime', is_nullable => 0, set_on_create => 1 }, diff --git a/lib/Lacuna/DB/Result/Log/EmpireRPC.pm b/lib/Lacuna/DB/Result/Log/EmpireRPC.pm index 81b5fe87..19952a11 100644 --- a/lib/Lacuna/DB/Result/Log/EmpireRPC.pm +++ b/lib/Lacuna/DB/Result/Log/EmpireRPC.pm @@ -8,8 +8,8 @@ use Lacuna::Util; __PACKAGE__->table('empire_rpc_log'); __PACKAGE__->add_columns( - rpc => { data_type => 'int', size => 11, is_nullable => 0, default => 0 }, - limits => { data_type => 'int', size => 11, is_nullable => 0, default => 0 }, + rpc => { data_type => 'int', size => 11, is_nullable => 0, default_value => 0 }, + limits => { data_type => 'int', size => 11, is_nullable => 0, default_value => 0 }, ); no Moose; diff --git a/lib/Lacuna/DB/Result/Probes.pm b/lib/Lacuna/DB/Result/Probes.pm index d7d48e01..fe075527 100644 --- a/lib/Lacuna/DB/Result/Probes.pm +++ b/lib/Lacuna/DB/Result/Probes.pm @@ -13,7 +13,7 @@ __PACKAGE__->add_columns( star_id => { data_type => 'int', is_nullable => 0 }, body_id => { data_type => 'int', is_nullable => 0 }, alliance_id => { data_type => 'int', is_nullable => 1 }, - virtual => { data_type => 'int', is_nullable => 1, default => 0 }, + virtual => { data_type => 'int', is_nullable => 1, default_value => 0 }, ); __PACKAGE__->belongs_to('empire', 'Lacuna::DB::Result::Empire', 'empire_id'); diff --git a/lib/Lacuna/DB/Result/Schedule.pm b/lib/Lacuna/DB/Result/Schedule.pm index ab1d401d..84f9bf8d 100644 --- a/lib/Lacuna/DB/Result/Schedule.pm +++ b/lib/Lacuna/DB/Result/Schedule.pm @@ -22,7 +22,7 @@ __PACKAGE__->add_columns( queue => {data_type => 'varchar', size => 30, is_nullable => 0}, job_id => {data_type => 'int', size => 11, is_nullable => 0}, delivery => {data_type => 'datetime', is_nullable => 0}, - priority => {data_type => 'int', size => 11, is_nullable => 0, default => 1000}, + priority => {data_type => 'int', size => 11, is_nullable => 0, default_value => 1000}, parent_table => {data_type => 'varchar', size => 30, is_nullable => 0}, parent_id => {data_type => 'int', size => 11, is_nullable => 0}, task => {data_type => 'varchar', size => 30, is_nullable => 0}, -- 2.51.2