mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-06-23 01:20:50 +00:00
Fix label count (#8267)
* fix label count * fix vendor * fix import order * update xorm to fix bug * fix tests * fix mssql bug
This commit is contained in:
parent
7cccada51e
commit
29dda47cbb
38 changed files with 959 additions and 580 deletions
36
vendor/xorm.io/builder/cond.go
generated
vendored
36
vendor/xorm.io/builder/cond.go
generated
vendored
|
@ -4,42 +4,6 @@
|
|||
|
||||
package builder
|
||||
|
||||
import (
|
||||
"io"
|
||||
)
|
||||
|
||||
// Writer defines the interface
|
||||
type Writer interface {
|
||||
io.Writer
|
||||
Append(...interface{})
|
||||
}
|
||||
|
||||
var _ Writer = NewWriter()
|
||||
|
||||
// BytesWriter implments Writer and save SQL in bytes.Buffer
|
||||
type BytesWriter struct {
|
||||
writer *StringBuilder
|
||||
args []interface{}
|
||||
}
|
||||
|
||||
// NewWriter creates a new string writer
|
||||
func NewWriter() *BytesWriter {
|
||||
w := &BytesWriter{
|
||||
writer: &StringBuilder{},
|
||||
}
|
||||
return w
|
||||
}
|
||||
|
||||
// Write writes data to Writer
|
||||
func (s *BytesWriter) Write(buf []byte) (int, error) {
|
||||
return s.writer.Write(buf)
|
||||
}
|
||||
|
||||
// Append appends args to Writer
|
||||
func (s *BytesWriter) Append(args ...interface{}) {
|
||||
s.args = append(s.args, args...)
|
||||
}
|
||||
|
||||
// Cond defines an interface
|
||||
type Cond interface {
|
||||
WriteTo(Writer) error
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue