fixing problems reported by SensioLabsInsight