Function isAllowedToAccessThisLocation

Determines whether a user has access to a specific route based on allow/deny rules.

This function checks the allow and deny properties of a route to determine if the user (userId) is permitted to access it, considering locationData.

  • Parameters

    • userId: string

      The ID of the user requesting access.

    • route: any

      The route object containing access rules (allow and deny).

    • locationData: any

      Additional data used to determine access permissions.

    Returns boolean

    • true if the user is allowed to access the location, otherwise false.