Updated paths for online players and banned players JSON files.
This commit is contained in:
@@ -20,7 +20,7 @@ class StaticsController < ApplicationController
|
|||||||
@players = []
|
@players = []
|
||||||
@count = 0
|
@count = 0
|
||||||
begin
|
begin
|
||||||
json = JSON.parse(File.read("/etc/minecraft/redstoner/plugins/ModuleLoader/players.json"))
|
json = JSON.parse(File.read("/etc/minecraft/info/players.json"))
|
||||||
rescue
|
rescue
|
||||||
flash.now[:alert] = "The server is currently offline."
|
flash.now[:alert] = "The server is currently offline."
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ class UsersController < ApplicationController
|
|||||||
|
|
||||||
def show
|
def show
|
||||||
begin
|
begin
|
||||||
@ban_json = JSON.parse(File.read("/etc/minecraft/redstoner/banned-players.json")).detect {|u| u["uuid"].tr("-", "") == @user.uuid}
|
@ban_json = JSON.parse(File.read("/etc/minecraft/info/banned-players.json")).detect {|u| u["uuid"].tr("-", "") == @user.uuid}
|
||||||
rescue
|
rescue
|
||||||
flash.now[:alert] = "An error occured while checking if this user is banned from the server!"
|
flash.now[:alert] = "An error occured while checking if this user is banned from the server!"
|
||||||
@ban_json = nil
|
@ban_json = nil
|
||||||
|
|||||||
Reference in New Issue
Block a user