Ernst fix resolving vector layer

Also store layerslug when there is no data but load finished, to prevent attaching a load listener that won't resolve. Tested in chromium and firefox