diff --git a/app/views/json/_current_hub.rabl b/app/views/json/_current_hub.rabl index 57731d9599..7f615bb07a 100644 --- a/app/views/json/_current_hub.rabl +++ b/app/views/json/_current_hub.rabl @@ -1,6 +1,8 @@ object current_distributor attributes :name, :id -child suppliers: :producers do - extends "json/producer" +if current_distributor + child suppliers: :producers do + extends "json/producer" + end end