Skip to content

Commit

Permalink
Fixed wrong version number for a couple of apps.
Browse files Browse the repository at this point in the history
Update copyright year in source files.
  • Loading branch information
mikechambers committed Jan 1, 2021
1 parent ac8e1db commit 2d8eff6
Show file tree
Hide file tree
Showing 55 changed files with 118 additions and 169 deletions.
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2020 Mike Chambers
Copyright (c) 2021 Mike Chambers

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
5 changes: 5 additions & 0 deletions RELEASE.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# dcli Release Notes

## v0.3.2 : January 1, 2021

* Fixed wrong version numbers in some apps
* Update Copyright year

## v0.3.1 : December 30, 2020

* Updated tests to run with latest release
Expand Down
18 changes: 9 additions & 9 deletions src/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/dcli/src/activitystoreinterface.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/apiclient.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
42 changes: 9 additions & 33 deletions src/dcli/src/apiinterface.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down Expand Up @@ -30,16 +30,13 @@ use crate::apiutils::{API_BASE_URL, PGCR_BASE_URL};
use crate::enums::mode::Mode;
use crate::enums::platform::Platform;
use crate::error::Error;
use crate::response::activities::{
ActivitiesResponse, Activity, MAX_ACTIVITIES_REQUEST_COUNT,
};
use crate::response::activities::{ActivitiesResponse, Activity, MAX_ACTIVITIES_REQUEST_COUNT};
use crate::response::character::CharacterData;
use crate::response::drs::API_RESPONSE_STATUS_SUCCESS;
use crate::response::gpr::{CharacterActivitiesData, GetProfileResponse};
use crate::response::pgcr::{DestinyPostGameCarnageReportData, PGCRResponse};
use crate::response::stats::{
AllTimePvPStatsResponse, DailyPvPStatsResponse, DailyPvPStatsValuesData,
PvpStatsData,
AllTimePvPStatsResponse, DailyPvPStatsResponse, DailyPvPStatsValuesData, PvpStatsData,
};
use crate::utils::Period;

Expand Down Expand Up @@ -137,9 +134,7 @@ impl ApiInterface {
Some(e) => e,
None => {
return Err(Error::ApiRequest {
description: String::from(
"No response data from API Call.",
),
description: String::from("No response data from API Call."),
})
}
};
Expand Down Expand Up @@ -286,14 +281,7 @@ impl ApiInterface {
// so assume we are out of data. (maybe compare to whether we have found any items).
// This would mean we might miss legitimate API errors though.
let activities = self
.retrieve_activities(
member_id,
character_id,
platform,
mode,
count,
page,
)
.retrieve_activities(member_id, character_id, platform, mode, count, page)
.await?;

if activities.is_none() {
Expand Down Expand Up @@ -362,14 +350,7 @@ impl ApiInterface {
// so assume we are out of data. (maybe compare to whether we have found any items).
// This would mean we might miss legitimate API errors though.
let activities = self
.retrieve_activities(
member_id,
character_id,
platform,
mode,
count,
page,
)
.retrieve_activities(member_id, character_id, platform, mode, count, page)
.await?;

if activities.is_none() {
Expand Down Expand Up @@ -455,9 +436,7 @@ impl ApiInterface {
return Ok(None);
} else {
return Err(Error::ApiRequest {
description: String::from(
"No response data from API Call.",
),
description: String::from("No response data from API Call."),
});
}
}
Expand All @@ -480,8 +459,7 @@ impl ApiInterface {
instance_id = instance_id,
);

let response: PGCRResponse =
self.client.call_and_parse::<PGCRResponse>(&url).await?;
let response: PGCRResponse = self.client.call_and_parse::<PGCRResponse>(&url).await?;

let data: DestinyPostGameCarnageReportData = match response.response {
Some(e) => e,
Expand All @@ -490,9 +468,7 @@ impl ApiInterface {
return Ok(None);
} else {
return Err(Error::ApiRequest {
description: String::from(
"No response data from API Call.",
),
description: String::from("No response data from API Call."),
});
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/apiutils.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/character.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/crucible.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
29 changes: 8 additions & 21 deletions src/dcli/src/cruciblestats.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand All @@ -23,8 +23,7 @@
use std::ops;

use crate::utils::{
calculate_efficiency, calculate_kills_deaths_assists,
calculate_kills_deaths_ratio,
calculate_efficiency, calculate_kills_deaths_assists, calculate_kills_deaths_ratio,
};

#[derive(Default, Debug)]
Expand Down Expand Up @@ -59,9 +58,7 @@ impl ops::Add<CrucibleStats> for CrucibleStats {
//but we will keep it here for completeness sake and in case the API is
//ever updated
let best_single_game_kills: Option<f32>;
if _cs.best_single_game_kills.is_none()
|| self.best_single_game_kills.is_none()
{
if _cs.best_single_game_kills.is_none() || self.best_single_game_kills.is_none() {
if _cs.best_single_game_kills.is_none() {
best_single_game_kills = self.best_single_game_kills;
} else {
Expand All @@ -75,8 +72,7 @@ impl ops::Add<CrucibleStats> for CrucibleStats {
}

let kills = self.kills + _cs.kills;
let total_kill_distance =
self.total_kill_distance + _cs.total_kill_distance;
let total_kill_distance = self.total_kill_distance + _cs.total_kill_distance;
let assists = self.assists + _cs.assists;
let deaths = self.deaths + _cs.deaths;

Expand All @@ -89,8 +85,7 @@ impl ops::Add<CrucibleStats> for CrucibleStats {

//todo : add activities_lost
CrucibleStats {
activities_entered: self.activities_entered
+ _cs.activities_entered,
activities_entered: self.activities_entered + _cs.activities_entered,
activities_won: self.activities_won + _cs.activities_won,
activities_lost: self.activities_lost + _cs.activities_lost,
assists,
Expand All @@ -101,17 +96,9 @@ impl ops::Add<CrucibleStats> for CrucibleStats {
deaths,
average_lifespan,
total_lifespan,
opponents_defeated: self.opponents_defeated
+ _cs.opponents_defeated,
efficiency: calculate_efficiency(
kills as u32,
deaths as u32,
assists as u32,
),
kills_deaths_ratio: calculate_kills_deaths_ratio(
kills as u32,
deaths as u32,
),
opponents_defeated: self.opponents_defeated + _cs.opponents_defeated,
efficiency: calculate_efficiency(kills as u32, deaths as u32, assists as u32),
kills_deaths_ratio: calculate_kills_deaths_ratio(kills as u32, deaths as u32),
kills_deaths_assists: calculate_kills_deaths_assists(
kills as u32,
deaths as u32,
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/emblem.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/enums/character.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/enums/itemtype.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/enums/medaltier.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/enums/mod.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/enums/mode.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/enums/moment.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/enums/platform.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/enums/standing.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/error.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/manifest/mod.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
2 changes: 1 addition & 1 deletion src/dcli/src/manifestinterface.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2020 Mike Chambers
* Copyright 2021 Mike Chambers
* https://github.com/mikechambers/dcli
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down
Loading

0 comments on commit 2d8eff6

Please sign in to comment.