Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
U
uw_cfg_common
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
WCMS
uw_cfg_common
Commits
c68ffbc7
Commit
c68ffbc7
authored
3 years ago
by
Eric Bremner
Committed by
Igor Biki
3 years ago
Browse files
Options
Downloads
Patches
Plain Diff
ISTWCMS-5195: fixing author on get node data
parent
09b761b8
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!169
Feature/istwcms 5195 ebremner node theming
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/Service/UwNodeFieldValue.php
+5
-6
5 additions, 6 deletions
src/Service/UwNodeFieldValue.php
with
5 additions
and
6 deletions
src/Service/UwNodeFieldValue.php
+
5
−
6
View file @
c68ffbc7
...
@@ -383,7 +383,6 @@ class UwNodeFieldValue {
...
@@ -383,7 +383,6 @@ class UwNodeFieldValue {
// Set the author to the person who made blog.
// Set the author to the person who made blog.
$author
=
[
$author
=
[
'name'
=>
$node
->
getOwner
()
->
getDisplayName
(),
'name'
=>
$node
->
getOwner
()
->
getDisplayName
(),
'link'
=>
NULL
,
];
];
}
}
...
@@ -393,11 +392,11 @@ class UwNodeFieldValue {
...
@@ -393,11 +392,11 @@ class UwNodeFieldValue {
// Get the link field from the node.
// Get the link field from the node.
$link
=
$node
->
field_uw_author_link
->
getValue
();
$link
=
$node
->
field_uw_author_link
->
getValue
();
// Set the
author
name
and link (if any).
$
author
[
'
name
'
]
=
$author_name
;
$author
=
[
'name'
=>
$author_name
,
if
(
!
empty
(
$link
))
{
'link'
=
>
empty
(
$link
)
?
NULL
:
$link
[
0
][
'uri'
]
,
$author
[
'link'
]
=
$link
[
0
][
'uri'
]
;
];
}
}
}
return
$author
;
return
$author
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment