EZP-22399 : When calling the method eZContentObject::relatedObjectCount with the IgnoreVisibility parameter, the count is not correct

Since inner_objet represents the source while outer_objet represents the target of the relationship, in the case of direct relationship, we want to check the visibility of the target, but not of the source !
On the other side, in the case of reverse relationships, outer_object and inner_object both represent the source object of the SQL query, and they could be interchanged on the condition $showInvisibleNodesCond without changing the result. (the SQL query is not symmetric).