experimental webdav upload
This commit is contained in:
parent
5e9ce5a306
commit
7570b09f9f
10 changed files with 47 additions and 2 deletions
|
|
@ -64,6 +64,14 @@ func (db *DB) CreateUser(username, password string) error {
|
|||
})
|
||||
}
|
||||
|
||||
func (db *DB) BasicAuth(username, password string) bool {
|
||||
_, err := db.Login(username, password)
|
||||
if err == nil {
|
||||
return true
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
func (db *DB) Login(username, password string) (u core.User, err error) {
|
||||
u, err = db.GetUser()
|
||||
if err != nil {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue