From d093b64101e58a60b4a7a2de37b6e8119129e8b8 Mon Sep 17 00:00:00 2001 From: "James D. Callahan III" Date: Mon, 22 Mar 2010 01:24:43 -0400 Subject: [PATCH] In Player:HasProperRepLevel(): If rep_data is nil, return true. Added return value at the end of the function. Oops. --- Player.lua | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Player.lua b/Player.lua index 5d541d1..10b188e 100644 --- a/Player.lua +++ b/Player.lua @@ -95,6 +95,9 @@ function Player:MarkExclusions() end function Player:HasProperRepLevel(rep_data) + if not rep_data then + return true + end local is_alliance = Player.faction == BFAC["Alliance"] local player_rep = Player["Reputation"] local FAC = private.faction_ids @@ -109,7 +112,7 @@ function Player:HasProperRepLevel(rep_data) end local rep_name = private.reputation_list[rep_id].name - if not player_rep[rep_name] or player_rep[rep_name] < rep_level then + if player_rep[rep_name] < rep_level then has_faction = false else has_faction = true @@ -117,6 +120,7 @@ function Player:HasProperRepLevel(rep_data) end end end + return has_faction end function Player:IsCorrectFaction(recipe_flags) -- 1.7.9.5