Re-break everything and fix Matrix->WhatsApp replies
This commit is contained in:
8
vendor/maunium.net/go/mautrix-appservice/generator.go
generated
vendored
8
vendor/maunium.net/go/mautrix-appservice/generator.go
generated
vendored
@ -44,14 +44,16 @@ func GenerateRegistration(asName, botName string, reserveRooms, reserveUsers boo
|
||||
boldCyan.Println("Generating appservice config and registration.")
|
||||
reader := bufio.NewReader(os.Stdin)
|
||||
|
||||
registration := CreateRegistration()
|
||||
config := Create()
|
||||
registration.RateLimited = false
|
||||
|
||||
name, err := readString(reader, "Enter name for appservice", asName)
|
||||
if err != nil {
|
||||
fmt.Println("Failed to read user Input:", err)
|
||||
return
|
||||
}
|
||||
registration := CreateRegistration(name)
|
||||
config := Create()
|
||||
registration.RateLimited = false
|
||||
registration.ID = name
|
||||
|
||||
registration.SenderLocalpart, err = readString(reader, "Enter bot username", botName)
|
||||
if err != nil {
|
||||
|
5
vendor/maunium.net/go/mautrix-appservice/http.go
generated
vendored
5
vendor/maunium.net/go/mautrix-appservice/http.go
generated
vendored
@ -1,11 +1,11 @@
|
||||
package appservice
|
||||
|
||||
import (
|
||||
"context"
|
||||
"encoding/json"
|
||||
"github.com/gorilla/mux"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"github.com/gorilla/mux"
|
||||
"context"
|
||||
"time"
|
||||
)
|
||||
|
||||
@ -106,7 +106,6 @@ func (as *AppService) PutTransaction(w http.ResponseWriter, r *http.Request) {
|
||||
}
|
||||
|
||||
for _, event := range eventList.Events {
|
||||
as.Log.Debugln("Received event", event.ID)
|
||||
as.UpdateState(event)
|
||||
as.Events <- event
|
||||
}
|
||||
|
2
vendor/maunium.net/go/mautrix-appservice/protocol.go
generated
vendored
2
vendor/maunium.net/go/mautrix-appservice/protocol.go
generated
vendored
@ -2,8 +2,8 @@ package appservice
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
"net/http"
|
||||
"maunium.net/go/gomatrix"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
// EventList contains a list of events.
|
||||
|
2
vendor/maunium.net/go/mautrix-appservice/registration.go
generated
vendored
2
vendor/maunium.net/go/mautrix-appservice/registration.go
generated
vendored
@ -21,7 +21,7 @@ type Registration struct {
|
||||
}
|
||||
|
||||
// CreateRegistration creates a Registration with random appservice and homeserver tokens.
|
||||
func CreateRegistration(name string) *Registration {
|
||||
func CreateRegistration() *Registration {
|
||||
return &Registration{
|
||||
AppToken: RandomString(64),
|
||||
ServerToken: RandomString(64),
|
||||
|
Reference in New Issue
Block a user