@@ -19,11 +19,10 @@ export default {
1919
2020 attributes : {
2121 timestamp : {
22- required : true ,
2322 order : 1 ,
2423 fillable : true ,
2524 validation : {
26- rule : schema . number ( ) ,
25+ rule : schema . number ( ) . required ( ) ,
2726 message : {
2827 date : 'Timestamp must be a valid date' ,
2928 } ,
@@ -32,11 +31,10 @@ export default {
3231 } ,
3332
3433 type : {
35- required : true ,
3634 order : 2 ,
3735 fillable : true ,
3836 validation : {
39- rule : schema . enum ( [ 'warning' , 'error' , 'info' , 'success' ] ) ,
37+ rule : schema . enum ( [ 'warning' , 'error' , 'info' , 'success' ] ) . required ( ) ,
4038 message : {
4139 enum : 'Type must be one of: warning, error, info, success' ,
4240 } ,
@@ -45,11 +43,10 @@ export default {
4543 } ,
4644
4745 source : {
48- required : true ,
4946 order : 3 ,
5047 fillable : true ,
5148 validation : {
52- rule : schema . enum ( [ 'file' , 'cli' , 'system' ] ) ,
49+ rule : schema . enum ( [ 'file' , 'cli' , 'system' ] ) . required ( ) ,
5350 message : {
5451 enum : 'Source must be one of: file, cli, system' ,
5552 } ,
@@ -58,11 +55,10 @@ export default {
5855 } ,
5956
6057 message : {
61- required : true ,
6258 order : 4 ,
6359 fillable : true ,
6460 validation : {
65- rule : schema . string ( ) . min ( 1 ) . max ( 1000 ) ,
61+ rule : schema . string ( ) . required ( ) . min ( 1 ) . max ( 1000 ) ,
6662 message : {
6763 min : 'Message must not be empty' ,
6864 max : 'Message must not exceed 1000 characters' ,
@@ -72,11 +68,10 @@ export default {
7268 } ,
7369
7470 project : {
75- required : true ,
7671 order : 5 ,
7772 fillable : true ,
7873 validation : {
79- rule : schema . string ( ) . min ( 1 ) . max ( 255 ) ,
74+ rule : schema . string ( ) . min ( 1 ) . required ( ) . max ( 255 ) ,
8075 message : {
8176 min : 'Project name must not be empty' ,
8277 max : 'Project name must not exceed 255 characters' ,
@@ -86,11 +81,10 @@ export default {
8681 } ,
8782
8883 stacktrace : {
89- required : false ,
9084 order : 6 ,
9185 fillable : true ,
9286 validation : {
93- rule : schema . string ( ) . max ( 5000 ) ,
87+ rule : schema . string ( ) . required ( ) . max ( 5000 ) ,
9488 message : {
9589 max : 'Stacktrace must not exceed 5000 characters' ,
9690 } ,
@@ -99,11 +93,10 @@ export default {
9993 } ,
10094
10195 file : {
102- required : false ,
10396 order : 7 ,
10497 fillable : true ,
10598 validation : {
106- rule : schema . string ( ) . max ( 255 ) ,
99+ rule : schema . string ( ) . required ( ) . max ( 255 ) ,
107100 message : {
108101 max : 'File path must not exceed 255 characters' ,
109102 } ,
0 commit comments