Skip to content

Commit 1759f5a

Browse files
committed
Update script format
1 parent 2a27c2a commit 1759f5a

File tree

1 file changed

+4
-8
lines changed

1 file changed

+4
-8
lines changed

TOOL-New-DjoinFile/New-DjoinFile.ps1

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
function New-DjoinFile
2-
{
1+
function New-DjoinFile {
32
<#
43
.SYNOPSIS
54
Function to generate a blob file accepted by djoin.exe tool (offline domain join)
@@ -41,10 +40,8 @@
4140
[System.IO.FileInfo]$DestinationFile = "c:\temp\djoin.tmp"
4241
)
4342

44-
PROCESS
45-
{
46-
TRY
47-
{
43+
PROCESS {
44+
TRY {
4845
# Create a byte object
4946
$bytechain = New-Object -TypeName byte[] -ArgumentList 2
5047
# Add the first two character for Unicode Encoding
@@ -66,8 +63,7 @@
6663
# Close the file Stream
6764
$FileStream.Close()
6865
}
69-
CATCH
70-
{
66+
CATCH {
7167
$Error[0]
7268
}
7369
}

0 commit comments

Comments
 (0)