Trim slash when building list endpoint URL

Created on 21 February 2023, over 1 year ago

The list endpoint URL is deduced from the accession URL. For instance, from https://brapi.url/v2/germplasm/{id}, we should get https://brapi.url/v2/germplasm when calling Brapi::getEndpoint(), but instead we get https://brapi.url/v2/germplasm/ (with a trailing slash). Depending on the implementation, we may get error codes like 404 or 301 in return. This final slash should be stripped out.

🐛 Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

🇫🇷France fmb Perpinyà, Catalonia, EU

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024