From aa672b00efff72408648fedb3114fd531df6ac6f Mon Sep 17 00:00:00 2001
From: gangov <6922910+gangov@users.noreply.github.com>
Date: Thu, 21 Nov 2024 13:15:08 +0200
Subject: [PATCH] removes the unnecessary ContractError

---
 contracts/deployer/src/lib.rs | 16 ++++------------
 1 file changed, 4 insertions(+), 12 deletions(-)

diff --git a/contracts/deployer/src/lib.rs b/contracts/deployer/src/lib.rs
index 8588fa3..70dd4c6 100644
--- a/contracts/deployer/src/lib.rs
+++ b/contracts/deployer/src/lib.rs
@@ -68,7 +68,7 @@ impl CollectionsDeployer {
         deployed_collection
     }
 
-    pub fn query_all_collections(env: &Env) -> Result<Vec<String>, ContractError> {
+    pub fn query_all_collections(env: &Env) -> Vec<String> {
         let maybe_all = env
             .storage()
             .persistent()
@@ -86,13 +86,13 @@ impl CollectionsDeployer {
                 )
             });
 
-        Ok(maybe_all)
+        maybe_all
     }
 
     pub fn query_collection_by_creator(
         env: &Env,
         creator: Address,
-    ) -> Result<Vec<CollectionByCreatorResponse>, ContractError> {
+    ) -> Vec<CollectionByCreatorResponse> {
         let data_key = DataKey::Creator(creator);
         let maybe_collections = env
             .storage()
@@ -106,7 +106,7 @@ impl CollectionsDeployer {
                 .extend_ttl(&data_key, LIFETIME_THRESHOLD, BUMP_AMOUNT)
         });
 
-        Ok(maybe_collections)
+        maybe_collections
     }
 }
 
@@ -128,14 +128,6 @@ pub enum DataKey {
     Creator(Address),
 }
 
-#[contracterror]
-#[derive(Copy, Clone, Debug, Eq, PartialEq, PartialOrd, Ord)]
-#[repr(u32)]
-pub enum ContractError {
-    NoCollectionsSaved = 0,
-    CreatorHasNoCollections = 1,
-}
-
 pub fn set_initialized(env: &Env) {
     env.storage().instance().set(&DataKey::IsInitialized, &());
     env.storage()