A
A
asmrnv7772016-04-25 18:47:06
Android
asmrnv777, 2016-04-25 18:47:06

Wall.get - response.parsedModel == null. Why?

Using the latest VK SDK for Android (1.6.7) to get posts from my wall:

VKParameters vkParameters = VKParameters.from(VKApiConst.USER_ID, SettingsManager.getInstance().getVkId());

        VKRequest vkRequest = VKApi.wall().get(vkParameters);
        vkRequest.executeWithListener(new VKRequest.VKRequestListener() {
            @Override
            public void onComplete(VKResponse response) {
                super.onComplete(response);

                VKList<VKApiPost> posts = (VKList<VKApiPost>) response.parsedModel;
                for (VKApiPost post : posts) {
                    Logger.i(GuestsActivity.class, "Post: " + post.getId());
                }
            }

            @Override
            public void onError(VKError error) {
                super.onError(error);
            }
        });

In the debugger, I see that there is a response, and moreover, it was parsed into a JSON object, but parsedModel == null:
28735aba44164ec3b4641d30c7536cab.png
Why is this possible?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
F
finCoder, 2016-07-01
@finCoder

You need to add an EXTENDED parameter to the request
Strange behavior, but one of the developers also talks about it

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question