History

Update AssetServerError enum to be camelcase

Ryan Huffman committed 11 years ago

Commit db92e311 parent 251203c6 files · +18 −18Browse files

Showing the changes to assignment-client/src/assets/SendAssetTask.cpp (1 of 6 files). Show all

Unified · Split

assignment-client/src/assets/SendAssetTask.cpp+4−4
@@ -55,7 +55,7 @@ void SendAssetTask::run() { · 54 unmodified lines
5555 replyPacketList->writePrimitive(messageID);
5656
5757 if (end <= start) {
58− writeError(replyPacketList.get(), AssetServerError::INVALID_BYTE_RANGE);
58+ writeError(replyPacketList.get(), AssetServerError::InvalidByteRange);
5959 } else {
6060 QString filePath = _resourcesDir.filePath(QString(hexHash) + "." + QString(extension));
6161
@@ -63,12 +63,12 @@ void SendAssetTask::run() { · 1 unmodified line
6363
6464 if (file.open(QIODevice::ReadOnly)) {
6565 if (file.size() < end) {
66− writeError(replyPacketList.get(), AssetServerError::INVALID_BYTE_RANGE);
66+ writeError(replyPacketList.get(), AssetServerError::InvalidByteRange);
6767 qCDebug(networking) << "Bad byte range: " << hexHash << " " << start << ":" << end;
6868 } else {
6969 auto size = end - start;
7070 file.seek(start);
71− replyPacketList->writePrimitive(AssetServerError::NO_ERROR);
71+ replyPacketList->writePrimitive(AssetServerError::NoError);
7272 replyPacketList->writePrimitive(size);
7373 replyPacketList->write(file.read(size));
7474 qCDebug(networking) << "Sending asset: " << hexHash;
@@ -76,7 +76,7 @@ void SendAssetTask::run() { · 1 unmodified line
7676 file.close();
7777 } else {
7878 qCDebug(networking) << "Asset not found: " << filePath << "(" << hexHash << ")";
79− writeError(replyPacketList.get(), AssetServerError::ASSET_NOT_FOUND);
79+ writeError(replyPacketList.get(), AssetServerError::AssetNotFound);
8080 }
8181 }
8282