clang-tidy readability
This commit is contained in:
@@ -73,9 +73,9 @@ void ManageHiScoreTable::sort() {
|
||||
auto ManageHiScoreTable::loadFromFile(const std::string &file_path) -> bool {
|
||||
clear();
|
||||
auto success = true;
|
||||
auto file = SDL_IOFromFile(file_path.c_str(), "rb");
|
||||
auto *file = SDL_IOFromFile(file_path.c_str(), "rb");
|
||||
|
||||
if (file) {
|
||||
if (file != nullptr) {
|
||||
table_.clear(); // Limpia la tabla actual
|
||||
|
||||
// Lee el número de entradas en la tabla
|
||||
@@ -119,9 +119,9 @@ auto ManageHiScoreTable::loadFromFile(const std::string &file_path) -> bool {
|
||||
// Guarda la tabla en un fichero
|
||||
auto ManageHiScoreTable::saveToFile(const std::string &file_path) -> bool {
|
||||
auto success = true;
|
||||
auto file = SDL_IOFromFile(file_path.c_str(), "w+b");
|
||||
auto *file = SDL_IOFromFile(file_path.c_str(), "w+b");
|
||||
|
||||
if (file) {
|
||||
if (file != nullptr) {
|
||||
// Guarda el número de entradas en la tabla
|
||||
int table_size = static_cast<int>(table_.size());
|
||||
SDL_WriteIO(file, &table_size, sizeof(int));
|
||||
|
||||
Reference in New Issue
Block a user