Skip to content

Commit

Permalink
Merge pull request #631 from storyblok/feat/resolve-links-link-support
Browse files Browse the repository at this point in the history
feat: link support for resolve_links
  • Loading branch information
Thiago Saife authored Aug 10, 2023
2 parents f4d4a6c + d987a7c commit 5d174b0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -494,7 +494,7 @@ class Storyblok {

if (
params.resolve_links &&
['1', 'story', 'url'].indexOf(params.resolve_links) > -1 &&
['1', 'story', 'url', 'link'].indexOf(params.resolve_links) > -1 &&
(responseData.links?.length || responseData.link_uuids?.length)
) {
await this.resolveLinks(responseData, params, resolveId)
Expand Down
4 changes: 2 additions & 2 deletions src/interfaces.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export interface ISbStoriesParams {
excluding_ids?: string
excluding_fields?: string
version?: 'draft' | 'published'
resolve_links?: 'url' | 'story' | '0' | '1' | 'link'
resolve_links?: 'link' | 'url' | 'story' | '0' | '1' | 'link'
resolve_relations?: string | string[]
resolve_assets?: number
cv?: number
Expand Down Expand Up @@ -42,7 +42,7 @@ export interface ISbStoryParams {
token?: string
find_by?: 'uuid'
version?: 'draft' | 'published'
resolve_links?: 'url' | 'story' | '0' | '1'
resolve_links?: 'link' | 'url' | 'story' | '0' | '1'
resolve_relations?: string | string[]
cv?: number
from_release?: string
Expand Down

0 comments on commit 5d174b0

Please sign in to comment.