change sam3 to i2pkeys in some places
This commit is contained in:
parent
a17ef742a2
commit
4ad3e7d4a0
8 changed files with 435 additions and 23 deletions
|
@ -9,7 +9,8 @@ import (
|
|||
)
|
||||
|
||||
import (
|
||||
"github.com/eyedeekay/sam3"
|
||||
"github.com/go-i2p/sam3"
|
||||
"github.com/go-i2p/i2pkeys"
|
||||
)
|
||||
|
||||
type Resolver struct {
|
||||
|
@ -24,8 +25,8 @@ func (r Resolver) Resolve(ctx context.Context, name string) (context.Context, ne
|
|||
return r.ResolveI2P(ctx, name)
|
||||
}
|
||||
|
||||
func (r Resolver) ResolveI2P(ctx context.Context, name string) (context.Context, *sam3.I2PAddr, error) {
|
||||
var n *sam3.I2PAddr
|
||||
func (r Resolver) ResolveI2P(ctx context.Context, name string) (context.Context, *i2pkeys.I2PAddr, error) {
|
||||
var n *i2pkeys.I2PAddr
|
||||
if !r.ValidateI2PAddr(name) {
|
||||
return ctx, n, fmt.Errorf("Error, not an allowed suffix")
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue