Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
I
intranet-rest
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
project-open
intranet-rest
Commits
d6c7c58a
Commit
d6c7c58a
authored
Jun 22, 2011
by
Frank Bergmann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- REST Interface:
Now reconstructing values of variables with empty string
parent
02fbefa4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
5 deletions
+10
-5
intranet-rest-create-procs.tcl
tcl/intranet-rest-create-procs.tcl
+10
-5
No files found.
tcl/intranet-rest-create-procs.tcl
View file @
d6c7c58a
...
...
@@ -733,27 +733,32 @@ ad_proc -private im_rest_post_object_type_user {
}
# Fake the following required variables
if
{
!
[
info
exists username
]}
{
if
{
!
[
info
exists username
]
||
""
==
$username
}
{
set username
"
$first
_names
$last
_name"
set hash_array
(
username
)
$username
ns_log Notice
"im_rest_post_object_type_
$rest
_otype: Set username=
$username
"
}
if
{
!
[
info
exists screen_name
]}
{
if
{
!
[
info
exists screen_name
]
||
""
==
$screen
_name
}
{
set screen_name
$username
set hash_array
(
screen_name
)
$screen
_name
ns_log Notice
"im_rest_post_object_type_
$rest
_otype: Set screen_name=
$screen
_name"
}
if
{
!
[
info
exists email
]}
{
if
{
!
[
info
exists email
]
||
""
==
$email
}
{
set email
"
${first_names}
.
${last_name}
@nowhere.com"
set email
[
string
tolower
$email
]
regsub -all
{[
^a-zA-Z0-9_
\-
@
]}
$email
"."
email
set hash_array
(
email
)
$email
ns_log Notice
"im_rest_post_object_type_
$rest
_otype: Set email=
$email
"
}
if
{
!
[
info
exists password
]}
{
if
{
!
[
info
exists password
]
||
""
==
$password
}
{
set password
[
ad_generate_random_string
]
set hash_array
(
password
)
$password
ns_log Notice
"im_rest_post_object_type_
$rest
_otype: Set password=
$password
"
}
if
{
!
[
info
exists url
]}
{
if
{
!
[
info
exists url
]
||
""
==
$url
}
{
set url
""
set hash_array
(
url
)
$url
ns_log Notice
"im_rest_post_object_type_
$rest
_otype: Set url=
$url
"
}
# Check for duplicate
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment