This code
final posts = (await wordpress.getAsync('posts'))['data'];
works fine.
But if you add a forward slash to the endpoint, flutter throws an exception:
Invalid argument(s): The source must not be null
Sample code: final posts = (await wordpress.getAsync('posts/1'))['data'];
This code
final posts = (await wordpress.getAsync('posts'))['data'];
works fine.But if you add a forward slash to the endpoint, flutter throws an exception: Invalid argument(s): The source must not be null Sample code:
final posts = (await wordpress.getAsync('posts/1'))['data'];