mirror of
https://github.com/overte-org/overte.git
synced 2025-08-10 16:23:17 +02:00
comment per cr
This commit is contained in:
parent
2deb26551f
commit
665870b846
1 changed files with 3 additions and 0 deletions
|
@ -231,6 +231,9 @@ void AvatarMixer::manageIdentityData(const SharedNodePointer& node) {
|
||||||
}
|
}
|
||||||
|
|
||||||
bool AvatarMixer::isAvatarInWhitelist(const QUrl& url) {
|
bool AvatarMixer::isAvatarInWhitelist(const QUrl& url) {
|
||||||
|
// The avatar is in the whitelist if:
|
||||||
|
// 1. The avatar's URL's host matches one of the hosts of the URLs in the whitelist AND
|
||||||
|
// 2. The avatar's URL's path starts with the path of that same URL in the whitelist
|
||||||
for (const auto& whiteListedPrefix : _avatarWhitelist) {
|
for (const auto& whiteListedPrefix : _avatarWhitelist) {
|
||||||
auto whiteListURL = QUrl::fromUserInput(whiteListedPrefix);
|
auto whiteListURL = QUrl::fromUserInput(whiteListedPrefix);
|
||||||
// check if this script URL matches the whitelist domain and, optionally, is beneath the path
|
// check if this script URL matches the whitelist domain and, optionally, is beneath the path
|
||||||
|
|
Loading…
Reference in a new issue