Giter Site home page Giter Site logo

gre's Introduction

Exceptions:

SessionException error codes.

Notes:

  • You should pass error number to SessionException once you throw it, don't pass a string message to SessionException as it will not work and will not construct the exception.
  • Passing number other than the listed will make exception return string with explainations, avoid it please and implement your exception class inherited from SessionException instead.

Error Codes:

SessionException:

Code Description
1 'login_email' is missing in session
2 'login_password' is missing in session
15 'login_token' is missing in session

InvalidArgumentException:

Code Description
3 email argument is not valid (either not an email string, or is empty)
4 password argument is not good (empty string)
5 user name argument is not valid (empty string)
6 the given log type is empty string
7 the given log value is empty string

Exception

Code Description
14 the given api key id doesn't exist in database

DBException

Code Description
8 wrong database connection data (hostname, username & password)
9 general error in a select query
10 general error in an insert query
11 general error in an update query
12 general error in a delete query
13 unknown error in the database process (you should set the message, otherwise no way

API error codes:

Code Description
15 login credentials are not correct
16 firstname (or lastname) is not provided in api request
17 current operation required to be logged in
18 you haven't sent data body for an api request that requires it
19 invalid http method for this api url

gre's People

Contributors

ahmedadel35 avatar gre-dev avatar omarrr95 avatar usama-makhzoum avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.