Advertisement
Guest User

Untitled

a guest
Apr 20th, 2018
53
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.61 KB | None | 0 0
  1. @Command("social")
  2. public final class SocialCommand {
  3.  
  4. @RequireCooldown(500)
  5. @CommandHandler("{site}")
  6. public void printTwitterLink(@BeanParameter("links") JsonElement commonLinks,
  7. @CommandArgument("site") String site,
  8. @CommandSender CommandSender requestee){
  9. JsonObject configurationObject = commonLinks.get(site);
  10. if(configurationObject==null) {
  11. requestee.sendMessage("media.unknown");
  12. }
  13.  
  14. requestee.sendMessage(configurationObject.getAsString());
  15. }
  16.  
  17.  
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement