We've released LIFF v2.26.1.
In LIFF v2.26.1, we've fixed the following bugs.
In a LIFF app, when accessing the LIFF URL, the LIFF app first navigates to the primary redirect URL and then to the secondary redirect URL. There was a bug in the conditions that append a slash (/
) to the end of the path of the secondary redirect URL, which caused the LIFF app to navigate to an unintended secondary redirect URL.
In LIFF v2.26.0 or earlier, a slash (/
) is appended to the end of the path of the secondary redirect URL if any of the following conditions are met:
- The endpoint URL ends with a slash (
/
) liff.state
ends with a slash (/
)
For example, if the LIFF app's endpoint URL is https://example.com/?key=value/
and the LIFF URL being accessed is https://liff.line.me/1234567890-AbcdEfgh/foo/bar
, the correct secondary redirect URL is https://example.com/foo/bar?key=value/
.
However, since the condition "the endpoint URL ends with a slash (/
)" is met in this situation, the LIFF app actually navigates to https://example.com/foo/bar/?key=value/
which has a slash (/
) added to the end of the path.
Correct secondary redirect URL | Actual secondary redirect URL |
---|
https://example.com/foo/bar?key=value/ | https://example.com/foo/bar/?key=value/ |
In LIFF v2.26.1, we've applied a fix so that a slash (/
) is appended to the end of the secondary redirect URL if any of the following conditions are met. As a result, LIFF apps now navigate to the correct secondary redirect URL.
- The endpoint URL's path ends with a slash (
/
) liff.state
's path ends with a slash (/
)
For more information about the behavior when accessing a LIFF URL, see Behaviors from accessing the LIFF URL to opening the LIFF app in the LIFF documentation.
In LIFF apps, when the liff.init()
method is resolved, credential information such as access tokens is excluded from URLs. At this time, there was a bug in some environments where POST requests were replaced with GET requests in the browser's session history.
In LIFF v2.26.1, we've fixed the bug so that the correct history is retained.
For example, suppose you interact with a LIFF app in the following order:
- Open a LIFF app
- Navigate to
/path1
with a POST request - Navigate to
/path2
with a GET request - Click the browser's back button
In this situation, the LIFF app is expected to navigate to /path1
with a POST request, but in some environments, the LIFF app navigates to /path1
with a GET request.
If you're using the CDN edge path (https://static.line-scdn.net/liff/edge/2/sdk.js
), you'll automatically update LIFF to v2.26.1.
If you're using an npm package, you can update to v2.26.1 by executing either npm install @line/liff@2.26.1
or yarn add @line/liff@2.26.1
.
For more information on integrating the LIFF SDK, see Integrating the LIFF SDK with the LIFF app in the LIFF documentation.