Keypad

Hello, i just need a help with my code i have did a keypad for door lock by using arduino uno my problem is when i put the code the arduino code take the last digit of my code for (example : if the code is 2580 when i push the 0 on the key pad the door is open) and her is my code :
#include <Keypad.h>
const byte ROWS =4;
const byte COLS =4;
char keys[ROWS][COLS]={
{'1','2','3','A'},
{'4','5','6','B'},
{'7','8','9','C'},
{'*','0','#','D'}
};
byte rowPins[ROWS]={2,3,4,5};
byte colPins[COLS]={6,7,8,9};
Keypad keypad = Keypad(makeKeymap(keys),rowPins,colPins,ROWS,COLS);
int relay =13;

void setup() {
// put your setup code here, to run once:
pinMode(relay, OUTPUT);
digitalWrite(relay,HIGH);
Serial.begin(9600);

}

void loop() {
// put your main code here, to run repeatedly:
char key = keypad.getKey();
char pass= '2580';
if (key==pass)
{digitalWrite(relay,LOW);
delay(2000);
digitalWrite(relay,HIGH);
}
}

keypad.getKey() returns a single key press or NO_KEY. It does not return your entire sequence at once. Look at the examples that come with the keypad library and start over.

One read returns one key only. To read a string: see keypad - password with Arduino