Page MenuHomePhorge

D25591.1732368647.diff
No OneTemporary

D25591.1732368647.diff

diff --git a/src/applications/almanac/management/AlmanacManagementRegisterWorkflow.php b/src/applications/almanac/management/AlmanacManagementRegisterWorkflow.php
--- a/src/applications/almanac/management/AlmanacManagementRegisterWorkflow.php
+++ b/src/applications/almanac/management/AlmanacManagementRegisterWorkflow.php
@@ -38,7 +38,7 @@
$viewer = $this->getViewer();
$device_name = $args->getArg('device');
- if (!strlen($device_name)) {
+ if (!phutil_nonempty_string($device_name)) {
throw new PhutilArgumentUsageException(
pht('Specify a device with --device.'));
}
@@ -55,7 +55,7 @@
$identify_as = $args->getArg('identify-as');
$raw_device = $device_name;
- if (strlen($identify_as)) {
+ if (phutil_nonempty_string($identify_as)) {
$raw_device = $identify_as;
}
@@ -70,7 +70,7 @@
}
$private_key_path = $args->getArg('private-key');
- if (!strlen($private_key_path)) {
+ if (!phutil_nonempty_string($private_key_path)) {
throw new PhutilArgumentUsageException(
pht('Specify a private key with --private-key.'));
}

File Metadata

Mime Type
text/plain
Expires
Sat, Nov 23, 13:30 (12 h, 58 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
991543
Default Alt Text
D25591.1732368647.diff (1 KB)

Event Timeline