Browse Source

private ads for nsfw

master
David Haukeness 5 years ago
parent
commit
5dc6e6e2e2
  1. 12
      main.go

12
main.go

@ -87,7 +87,7 @@ func run(c *cli.Context) error { @@ -87,7 +87,7 @@ func run(c *cli.Context) error {
if c.String("owner") != "" {
b.Meta["owner"] = c.String("owner")
}
if c.String("kbstore-team") != "" {
if c.String("kvstore-team") != "" {
b.Meta["kvstore"] = c.String("kvstore-team")
loadNsfwAllowed(b)
}
@ -102,6 +102,7 @@ func run(c *cli.Context) error { @@ -102,6 +102,7 @@ func run(c *cli.Context) error {
keybasebot.BotCommand{
Name: "ping",
Ad: &cmd.PingAd,
AdType: "public",
Run: keybasebot.Adapt(
cmd.SendPong,
keybasebot.MessageType("text"),
@ -111,6 +112,7 @@ func run(c *cli.Context) error { @@ -111,6 +112,7 @@ func run(c *cli.Context) error {
keybasebot.BotCommand{
Name: "age",
Ad: &cmd.AgeAd,
AdType: "public",
Run: keybasebot.Adapt(
cmd.Age,
keybasebot.MessageType("text"),
@ -120,6 +122,7 @@ func run(c *cli.Context) error { @@ -120,6 +122,7 @@ func run(c *cli.Context) error {
keybasebot.BotCommand{
Name: "convert",
Ad: &cmd.ConvertAd,
AdType: "public",
Run: keybasebot.Adapt(
cmd.Convert,
keybasebot.MessageType("text"),
@ -129,6 +132,7 @@ func run(c *cli.Context) error { @@ -129,6 +132,7 @@ func run(c *cli.Context) error {
keybasebot.BotCommand{
Name: "price",
Ad: &cmd.PriceAd,
AdType: "public",
Run: keybasebot.Adapt(
cmd.SendPrice,
keybasebot.MessageType("text"),
@ -137,9 +141,11 @@ func run(c *cli.Context) error { @@ -137,9 +141,11 @@ func run(c *cli.Context) error {
},
keybasebot.BotCommand{
Name: "nsfw",
Ad: nil,
Ad: &cmd.NsfwAd,
AdType: "teammembers",
AdTeamName: c.String("kvstore-team"),
Run: keybasebot.Adapt(
setNsfw,
cmd.SetNsfw,
keybasebot.MessageType("text"),
keybasebot.CommandPrefix("!nsfw"),
keybasebot.FromUser(c.String("owner")),

Loading…
Cancel
Save