Fixed bug where a resource would be created under the first category