Skip to content

Commit

Permalink
0.64.25 Add create vote_custom access-right
Browse files Browse the repository at this point in the history
  • Loading branch information
araszka committed May 3, 2019
1 parent e41c564 commit 6d73974
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions core/Modules/votes/Votes.php
Expand Up @@ -10,6 +10,7 @@
use esc\Classes\Template;
use esc\Classes\Timer;
use esc\Controllers\MapController;
use esc\Models\AccessRight;
use esc\Models\Player;
use Illuminate\Support\Collection;

Expand Down Expand Up @@ -46,6 +47,8 @@ public function __construct()
Log::error('Failed to get config "votes.vote-limit". Setting limit to 1.');
}

AccessRight::createIfNonExistent('vote_custom', 'Create a custom vote. Enter question after command.');

ChatCommand::add('//vote', [self::class, 'startVoteQuestion'], 'Start a custom vote.', 'vote_custom');
ChatCommand::add('/skip', [self::class, 'askSkip'], 'Start a vote to skip map.');
ChatCommand::add('/y', [self::class, 'voteYes'], 'Vote yes.');
Expand Down

0 comments on commit 6d73974

Please sign in to comment.