Skip to content

Commit 9ca3773

Browse files
committed
Review fixups
1 parent 8c17d93 commit 9ca3773

File tree

2 files changed

+5
-8
lines changed

2 files changed

+5
-8
lines changed

REFERENCE.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6696,11 +6696,11 @@ Default value: ``undef``
66966696

66976697
##### <a name="userdir"></a>`userdir`
66986698

6699-
Data type: `Any`
6699+
Data type: `Optional[String[1]]`
67006700

6701-
Directory out of which per-user content is loaded. It may be any valid `UserDir` directive values.
6701+
Path or directory name to be used as the UserDir.
67026702

6703-
Default value: The value of `$path`
6703+
Default value: ``undef``
67046704

67056705
##### <a name="disable_root"></a>`disable_root`
67066706

manifests/mod/userdir.pp

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
class apache::mod::userdir (
3737
$home = undef,
3838
$dir = undef,
39-
$userdir = undef,
39+
Optional[String[1]] $userdir = undef,
4040
$disable_root = true,
4141
$apache_version = undef,
4242
$path = '/home/*/public_html',
@@ -63,10 +63,7 @@
6363
$_path = $path
6464
}
6565

66-
$_userdir = $userdir ? {
67-
undef => $_path,
68-
default => $userdir,
69-
}
66+
$_userdir = pick($userdir, $_path)
7067

7168
::apache::mod { 'userdir': }
7269

0 commit comments

Comments
 (0)