|
1 | | -import Sugar |
2 | | - |
3 | | -extension Configs { |
4 | | - static let CrossPost = CrossPostServiceConfig( |
5 | | - timeSpan: 60 * 2, |
6 | | - includeMessage: { message in |
7 | | - return message.text.components(separatedBy: " ").count > 5 |
8 | | - }, |
9 | | - reportingTarget: "admins", |
10 | | - publicWarning: { channel, user in |
11 | | - return try SlackMessage() |
12 | | - .line(user, " cross posting is discouraged.") |
13 | | - .makeChatPostMessage(target: channel) |
14 | | - }, |
15 | | - privateWarning: { im in |
16 | | - return try SlackMessage() |
17 | | - .line("Please refrain from cross posting, it is discouraged here.") |
18 | | - .makeChatPostMessage(target: im) |
19 | | - } |
20 | | - ) |
21 | | -} |
| 1 | +//import Sugar |
| 2 | +// |
| 3 | +//extension Configs { |
| 4 | +// static let CrossPost = CrossPostServiceConfig( |
| 5 | +// timeSpan: 60 * 2, |
| 6 | +// includeMessage: { message in |
| 7 | +// return message.text.components(separatedBy: " ").count > 5 |
| 8 | +// }, |
| 9 | +// reportingTarget: "admins", |
| 10 | +// publicWarning: { channel, user in |
| 11 | +// return try SlackMessage() |
| 12 | +// .line(user, " cross posting is discouraged.") |
| 13 | +// .makeChatPostMessage(target: channel) |
| 14 | +// }, |
| 15 | +// privateWarning: { im in |
| 16 | +// return try SlackMessage() |
| 17 | +// .line("Please refrain from cross posting, it is discouraged here.") |
| 18 | +// .makeChatPostMessage(target: im) |
| 19 | +// } |
| 20 | +// ) |
| 21 | +//} |
0 commit comments