src/Curiosity.Migrations/DbMigrator.cs
/// <summary>
/// Check permission to migrate using specified policy
/// </summary>
/// <param name="versionDifference"></param>
/// <param name="policy"></param>
/// <returns></returns>
Check permission to migrate using specified policy
Check permission to migrate using specified policy
private bool IsMigrationAllowed(DbVersionDifference versionDifference, MigrationPolicy policy)
        {
            switch (versionDifference)
            {
                case DbVersionDifference.Major:
                    return policy.HasFlag(MigrationPolicy.Major);
                case DbVersionDifference.Minor:
                    return policy.HasFlag(MigrationPolicy.Minor);
                default:
                    return false;
            }
        }
private bool IsMigrationAllowed ( DbVersionDifference versionDifference , MigrationPolicy policy ) { switch ( versionDifference ) { case DbVersionDifference . Major : return policy . HasFlag ( MigrationPolicy . Major ) ; case DbVersionDifference . Minor : return policy . HasFlag ( MigrationPolicy . Minor ) ; default : return false ; } }
Check permission to migrate using specified policy
Check permission to migrate using specified policy
None
versionDifference
DbVersionDifference
None
policy
MigrationPolicy
None