dgervalle/xwiki-platform — comment on commit a80fe5de8dd21830aa8ae7fbf74f44e4115bc287
File: xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/doc/XWikiDocument.java line 563
By sdumitriu:

getLastSpaceReference is a shortcut that works well enough currently because we don't have proper support for nested spaces. Still, I prefer that we take a forward-thinking approach and make use of all the space references present in the document identity.