simplify IsOracle()
This commit is contained in:
parent
de34a5f3a2
commit
5b26d4ba08
8
scope.go
8
scope.go
@ -8,7 +8,6 @@ import (
|
||||
"fmt"
|
||||
"reflect"
|
||||
"regexp"
|
||||
"sort"
|
||||
"strings"
|
||||
"time"
|
||||
)
|
||||
@ -1426,10 +1425,5 @@ func (scope *Scope) hasConditions() bool {
|
||||
}
|
||||
|
||||
func (scope *Scope) IsOracle() bool {
|
||||
oraModules := []string{"godror", "oci8", "ora"} // must be an asc sorted slice
|
||||
insertAt := sort.SearchStrings(oraModules, scope.Dialect().GetName())
|
||||
if insertAt < len(oraModules) && oraModules[insertAt] == scope.Dialect().GetName() {
|
||||
return true
|
||||
}
|
||||
return false
|
||||
return scope.Dialect().GetName() == "oci8"
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user