Skip to content

Commit

Permalink
Replace "can't" with "cannot" in some logging
Browse files Browse the repository at this point in the history
  • Loading branch information
locka99 committed Apr 6, 2019
1 parent 0994fdb commit 3f2549a
Show file tree
Hide file tree
Showing 8 changed files with 13 additions and 13 deletions.
6 changes: 3 additions & 3 deletions client/src/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ impl Client {
// Ask the server associated with the default endpoint for its list of endpoints
let endpoints = match self.get_server_endpoints() {
Result::Err(status_code) => {
error!("Can't get endpoints for server, error - {}", status_code);
error!("Cannot get endpoints for server, error - {}", status_code);
return Err(status_code);
}
Result::Ok(endpoints) => endpoints
Expand Down Expand Up @@ -449,7 +449,7 @@ impl Client {
Err(StatusCode::BadUnexpectedError)
}
} else {
error!("Can't find an endpoint that we call register server on");
error!("Cannot find an endpoint that we call register server on");
Err(StatusCode::BadUnexpectedError)
}
}
Expand Down Expand Up @@ -535,7 +535,7 @@ impl Client {
security_mode: MessageSecurityMode) -> Option<EndpointDescription>
{
if security_policy == SecurityPolicy::Unknown {
panic!("Can't match against unknown security policy");
panic!("Cannot match against unknown security policy");
}

let matching_endpoint = endpoints.iter().find(|e| {
Expand Down
2 changes: 1 addition & 1 deletion core/src/comms/chunker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ impl Chunker {
}
}
Err(err) => {
debug!("Can't decode message {:?}, err = {:?}", object_id, err);
debug!("Cannot decode message {:?}, err = {:?}", object_id, err);
Err(StatusCode::BadServiceUnsupported)
}
}
Expand Down
4 changes: 2 additions & 2 deletions core/src/comms/message_chunk_info.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ impl ChunkInfo {
let security_header = if chunk.is_open_secure_channel(&decoding_limits) {
let result = AsymmetricSecurityHeader::decode(&mut stream, &decoding_limits);
if result.is_err() {
error!("chunk_info() can't decode asymmetric security_header, {}", result.unwrap_err());
error!("chunk_info() cannot decode asymmetric security_header, {}", result.unwrap_err());
return Err(StatusCode::BadCommunicationError);
}
let security_header = result.unwrap();
Expand All @@ -67,7 +67,7 @@ impl ChunkInfo {
} else {
let result = SymmetricSecurityHeader::decode(&mut stream, &decoding_limits);
if result.is_err() {
error!("chunk_info() can't decode symmetric security_header, {}", result.unwrap_err());
error!("chunk_info() cannot decode symmetric security_header, {}", result.unwrap_err());
return Err(StatusCode::BadCommunicationError);
}
SecurityHeader::Symmetric(result.unwrap())
Expand Down
2 changes: 1 addition & 1 deletion samples/discovery-client/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ fn main() {
// Ask the server associated with the default endpoint for its list of endpoints
match client.get_server_endpoints_from_url(discovery_url.as_ref()) {
Result::Err(status_code) => {
println!(" ERROR: Can't get endpoints for this server url, error - {}", status_code);
println!(" ERROR: Cannot get endpoints for this server url, error - {}", status_code);
continue;
}
Result::Ok(endpoints) => {
Expand Down
2 changes: 1 addition & 1 deletion server/src/comms/tcp_transport.rs
Original file line number Diff line number Diff line change
Expand Up @@ -637,7 +637,7 @@ impl TcpTransport {
if let Some(publish_responses) = session.subscriptions.take_publish_responses() {
match subscription_tx.unbounded_send(SubscriptionEvent::PublishResponses(publish_responses)) {
Err(error) => {
error!("Can't send publish responses, err = {}", error);
error!("Cannot send publish responses, err = {}", error);
}
Ok(_) => {
trace!("Sent publish responses to session task");
Expand Down
2 changes: 1 addition & 1 deletion server/src/subscriptions/monitored_item.rs
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ impl MonitoredItem {
false
}
} else {
trace!("Can't find item to monitor, node {:?}", self.item_to_monitor.node_id);
trace!("Cannot find item to monitor, node {:?}", self.item_to_monitor.node_id);
false
}
}
Expand Down
4 changes: 2 additions & 2 deletions server/src/subscriptions/subscriptions.rs
Original file line number Diff line number Diff line change
Expand Up @@ -282,11 +282,11 @@ impl Subscriptions {
debug!("Removing subscription {} sequence number {} from retransmission queue", subscription_id, sequence_number);
StatusCode::Good
} else {
error!("Can't find acknowledged notification with sequence number {}", sequence_number);
error!("Cannot find acknowledged notification with sequence number {}", sequence_number);
StatusCode::BadSequenceNumberUnknown
}
} else {
error!("Can't find acknowledged notification subscription id {}", subscription_id);
error!("Cannot find acknowledged notification subscription id {}", subscription_id);
StatusCode::BadSubscriptionIdInvalid
}
})
Expand Down
4 changes: 2 additions & 2 deletions types/src/variant.rs
Original file line number Diff line number Diff line change
Expand Up @@ -912,15 +912,15 @@ impl Variant {
Variant::DataValue(_) => Some(DataTypeId::DataValue),
Variant::Array(ref values) => {
if values.is_empty() {
error!("Can't get the data type of an empty array");
error!("Cannot get the data type of an empty array");
None
} else {
values[0].data_type()
}
}
Variant::MultiDimensionArray(ref mda) => {
if mda.values.is_empty() {
error!("Can't get the data type of an empty array");
error!("Cannot get the data type of an empty array");
None
} else {
mda.values[0].data_type()
Expand Down

0 comments on commit 3f2549a

Please sign in to comment.