This repository was archived by the owner on Dec 24, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +3
-4
lines changed
ServiceStack.OrmLite.SqlServer Expand file tree Collapse file tree 2 files changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -54,10 +54,9 @@ public override List<string> SequenceList(Type tableType)
54
54
55
55
foreach ( var fieldDef in modelDef . FieldDefinitions )
56
56
{
57
- if ( fieldDef . AutoIncrement || ! fieldDef . Sequence . IsNullOrEmpty ( ) )
57
+ if ( ! string . IsNullOrEmpty ( fieldDef . Sequence ) )
58
58
{
59
- if ( gens . IndexOf ( fieldDef . Sequence ) == - 1 )
60
- gens . Add ( fieldDef . Sequence ) ;
59
+ gens . AddIfNotExists ( fieldDef . Sequence ) ;
61
60
}
62
61
}
63
62
return gens ;
Original file line number Diff line number Diff line change @@ -160,7 +160,7 @@ internal static ModelDefinition GetModelDefinition(this Type modelType)
160
160
IsReference = referenceAttr != null && propertyType . IsClass ,
161
161
GetValueFn = propertyInfo . CreateGetter ( ) ,
162
162
SetValueFn = propertyInfo . CreateSetter ( ) ,
163
- Sequence = sequenceAttr != null ? sequenceAttr . Name : string . Empty ,
163
+ Sequence = sequenceAttr ? . Name ,
164
164
IsComputed = computeAttr != null || computedAttr != null || customSelectAttr != null ,
165
165
ComputeExpression = computeAttr != null ? computeAttr . Expression : string . Empty ,
166
166
CustomSelect = customSelectAttr ? . Sql ,
You can’t perform that action at this time.
0 commit comments