getPublicAccess(resourceURL, doAutoAuth = true)
The pods:getPublicAccess()
function returns a boolean that represents the public read
permission of the specified resource.
The pods:getPublicAccess()
function has the following parameters:
resourceURL — A required string parameter that informs the library what resource is to be checked for the
read
permission. The resource can be a folder or a file. This should be a full, absolute URL with anhttp
scheme (e.g. for a folder:http://examplepodserver:org/podName/myPhotos/folder/
, for a file:http://examplepodserver:org/podName/myPhotos/file.txt
) and a folder does require a slash at the end.doAutoAuth — An optional boolean parameter that controls automatic authentication attempts. It defaults to true if nothing is passed in for it. When true, the library will check that the stored authentication token is valid if it exists, and if the token is not valid or the token does not exist, the library will attempt to automatically authenticate once.
Copyright Picolabs | Licensed under Creative Commons.