mirror of
https://github.com/oceanprotocol/docs.git
synced 2024-11-26 19:49:26 +01:00
fix for showing links on all repos
This commit is contained in:
parent
441f19da69
commit
026587c409
@ -224,17 +224,17 @@ const Repository = ({ name, links, readme }) => (
|
||||
|
||||
// enhance passed links array with what's in repositories.yml,
|
||||
// iterating over all repos until we have a name match
|
||||
const linksFilteredArray = repositoriesYaml.map(({ node }) => {
|
||||
return node.items
|
||||
.map(item => {
|
||||
let linksFilteredArray = []
|
||||
|
||||
repositoriesYaml.map(({ node }) => {
|
||||
node.items.forEach(item => {
|
||||
if (item.name === name) {
|
||||
return item.links
|
||||
linksFilteredArray.push(item.links)
|
||||
}
|
||||
})
|
||||
.filter(n => n)[0]
|
||||
})
|
||||
|
||||
const moreLinks = links || linksFilteredArray[0]
|
||||
const moreLinks = links || linksFilteredArray.filter(n => n)[0]
|
||||
|
||||
return (
|
||||
<article className={styles.repository}>
|
||||
|
Loading…
Reference in New Issue
Block a user