Skip to content

Commit

Permalink
Revert "Unify Display implementations to be lowercase"
Browse files Browse the repository at this point in the history
This reverts commit 3cfc28b.
  • Loading branch information
raskchanky committed Oct 31, 2018
1 parent e6cccc9 commit d3a3d4e
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 27 deletions.
13 changes: 0 additions & 13 deletions components/butterfly/src/protocol/newscast.rs
Expand Up @@ -12,8 +12,6 @@
// See the License for the specific language governing permissions and
// limitations under the License.

use std::fmt;

use rumor::departure::Departure as CDeparture;
use rumor::election::{Election as CElection, ElectionUpdate as CElectionUpdate};
use rumor::service::Service as CService;
Expand All @@ -24,17 +22,6 @@ include!("../generated/butterfly.newscast.rs");

pub use self::{rumor::Payload as RumorPayload, rumor::Type as RumorType};

impl fmt::Display for election::Status {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
let value = match *self {
election::Status::Running => "running",
election::Status::NoQuorum => "no-quorum",
election::Status::Finished => "finished",
};
write!(f, "{}", value)
}
}

impl From<CDeparture> for Rumor {
fn from(value: CDeparture) -> Self {
let payload = Departure {
Expand Down
24 changes: 12 additions & 12 deletions components/sup/doc/http_gateway_butterfly_schema.json
Expand Up @@ -115,9 +115,9 @@
"status": {
"description": "The status of the election",
"enum": [
"running",
"no-quorum",
"finished"
"Running",
"NoQuorum",
"Finished"
]
},
"suitability": {
Expand Down Expand Up @@ -159,9 +159,9 @@
"status": {
"description": "The status of the election",
"enum": [
"running",
"no-quorum",
"finished"
"Running",
"NoQuorum",
"Finished"
]
},
"suitability": {
Expand Down Expand Up @@ -276,9 +276,9 @@
"status": {
"description": "The status of the election",
"enum": [
"running",
"no-quorum",
"finished"
"Running",
"NoQuorum",
"Finished"
]
},
"suitability": {
Expand Down Expand Up @@ -318,9 +318,9 @@
"status": {
"description": "The status of the election",
"enum": [
"running",
"no-quorum",
"finished"
"Running",
"NoQuorum",
"Finished"
]
},
"suitability": {
Expand Down
Expand Up @@ -16,7 +16,7 @@
"from_id": "d0cde5615a11461fa35fe4cbb1ab2644",
"member_id": "d0cde5615a11461fa35fe4cbb1ab2644",
"service_group": "witcher.prod",
"status": "finished",
"status": "Finished",
"suitability": 0,
"term": 0,
"votes": [
Expand All @@ -36,7 +36,7 @@
"from_id": "d0cde5615a11461fa35fe4cbb1ab2644",
"member_id": "d0cde5615a11461fa35fe4cbb1ab2644",
"service_group": "witcher.prod",
"status": "finished",
"status": "Finished",
"suitability": 0,
"term": 0,
"votes": [
Expand Down

0 comments on commit d3a3d4e

Please sign in to comment.