Author: chathura
Date: Tue Jan 29 01:23:41 2008
New Revision: 13122
Log:
Resolved REGISTRY 140.
Modified:
branches/registry/1_0/modules/core/src/main/java/org/wso2/registry/jdbc/JDBCRegistry.java
Modified:
branches/registry/1_0/modules/core/src/main/java/org/wso2/registry/jdbc/JDBCRegistry.java
==============================================================================
---
branches/registry/1_0/modules/core/src/main/java/org/wso2/registry/jdbc/JDBCRegistry.java
(original)
+++
branches/registry/1_0/modules/core/src/main/java/org/wso2/registry/jdbc/JDBCRegistry.java
Tue Jan 29 01:23:41 2008
@@ -197,7 +197,13 @@
resource = mediaTypeManager.get(path);
}
- if (resource == null || resource.getState() ==
RegistryConstants.DELETED_STATE) {
+ if (resource == null) {
+ throw new ResourceNotFoundException(path);
+ }
+
+ // if the request is for the current version of the resource, it
should not be in the
+ // deleted state.
+ if (path.indexOf("?v=") == -1 && resource.getState() ==
RegistryConstants.DELETED_STATE) {
throw new ResourceNotFoundException(path);
}
_______________________________________________
Registry-dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/registry-dev