Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
chore(shim-opentracing): better function name
  • Loading branch information
vreynolds committed May 26, 2021
commit 1e64f3be3419a803a4cabc5eed98ff22be00d271
6 changes: 3 additions & 3 deletions packages/opentelemetry-shim-opentracing/src/shim.ts
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@ export class SpanShim extends opentracing.Span {
*/
addTags(keyValueMap: SpanAttributes): this {
for (const [key, value] of Object.entries(keyValueMap)) {
if (this._setSpanStatusCode(key, value)) {
if (this._setErrorAsSpanStatusCode(key, value)) {
continue;
}
if (value !== undefined) {
Expand All @@ -317,7 +317,7 @@ export class SpanShim extends opentracing.Span {
* @param value value for the tag
*/
setTag(key: string, value: SpanAttributeValue): this {
if (this._setSpanStatusCode(key, value)) {
if (this._setErrorAsSpanStatusCode(key, value)) {
return this;
}

Expand All @@ -342,7 +342,7 @@ export class SpanShim extends opentracing.Span {
return this._span;
}

private _setSpanStatusCode(
private _setErrorAsSpanStatusCode(
key: string,
value: SpanAttributeValue | undefined
): boolean {
Expand Down