❔ accessing collections via principal entity vs directly on dbset
what is generally preferred if i want the accommodations of a listing (WITH resource ownership check included, so firstasync is intentional here)? s
Doing this:
or actually querying accommodations directly?
I find that the above seems better, since it will immediately return the request if the user does not have access. whereas if we query accommodations, it's going to reutnr an empty list and then continue
I guess my question pertains in general to resource ownership and accessing a collection items via prinicipal entity vs directly on the dbset.
My strategy is generally to use firstasync since if the user is not the owner of the listing, they have likely tampered with the inspector or some such to finagle the resource
Doing this:
or actually querying accommodations directly?
I find that the above seems better, since it will immediately return the request if the user does not have access. whereas if we query accommodations, it's going to reutnr an empty list and then continue
I guess my question pertains in general to resource ownership and accessing a collection items via prinicipal entity vs directly on the dbset.
My strategy is generally to use firstasync since if the user is not the owner of the listing, they have likely tampered with the inspector or some such to finagle the resource