Skip to content

Commit c75a71b

Browse files
authored
Graphite missing hostname fix (librenms#17955)
1 parent 48f2cf5 commit c75a71b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

LibreNMS/Data/Store/Graphite.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ public function write(string $measurement, array $fields, array $tags = [], arra
9191

9292
// metrics will be built as prefix.hostname.measurement.field value timestamp
9393
// metric fields can not contain . as this is used by graphite as a field separator
94-
$hostname = preg_replace('/\./', '_', $hostname);
94+
$hostname = preg_replace('/\./', '_', (string) $hostname);
9595
$measurement = preg_replace(['/\./', '/\//'], '_', $measurement);
9696
$measurement = preg_replace('/\|/', '.', $measurement);
9797

0 commit comments

Comments
 (0)