fixes for styling and logging from CR

This commit is contained in:
Stephen Birarda 2016-03-15 11:26:20 -07:00
parent b8abb1b6dd
commit 29cd487f84
3 changed files with 3 additions and 9 deletions

View file

@ -222,8 +222,7 @@ void AssetServer::handleGetMappingOperation(ReceivedMessage& message, SharedNode
auto assetHash = it->toString(); auto assetHash = it->toString();
replyPacket.writePrimitive(AssetServerError::NoError); replyPacket.writePrimitive(AssetServerError::NoError);
replyPacket.write(QByteArray::fromHex(assetHash.toUtf8())); replyPacket.write(QByteArray::fromHex(assetHash.toUtf8()));
} } else {
else {
replyPacket.writePrimitive(AssetServerError::AssetNotFound); replyPacket.writePrimitive(AssetServerError::AssetNotFound);
} }
} }
@ -578,7 +577,7 @@ bool AssetServer::deleteMappings(AssetPathList& paths) {
if (sizeBefore != sizeNow) { if (sizeBefore != sizeNow) {
qDebug() << "Deleted" << sizeBefore - sizeNow << "mappings in folder: " << path; qDebug() << "Deleted" << sizeBefore - sizeNow << "mappings in folder: " << path;
} else { } else {
qDebug() << "Did not find any mappings in folder:" << path; qDebug() << "Did not find any mappings to delete in folder:" << path;
} }
} else { } else {

View file

@ -225,8 +225,7 @@ void AssetMappingModel::refresh() {
lastItem = item; lastItem = item;
_pathToItemMap[fullPath] = lastItem; _pathToItemMap[fullPath] = lastItem;
} } else {
else {
lastItem = it.value(); lastItem = it.value();
} }
} }

View file

@ -50,10 +50,6 @@ void AssetScriptingInterface::downloadData(QString urlString, QScriptValue callb
auto parts = path.split(".", QString::SkipEmptyParts); auto parts = path.split(".", QString::SkipEmptyParts);
auto hash = parts.length() > 0 ? parts[0] : ""; auto hash = parts.length() > 0 ? parts[0] : "";
if (hash.length() != SHA256_HASH_HEX_LENGTH) {
return;
}
auto assetClient = DependencyManager::get<AssetClient>(); auto assetClient = DependencyManager::get<AssetClient>();
auto assetRequest = assetClient->createRequest(hash); auto assetRequest = assetClient->createRequest(hash);