Amongst many other logic I wrote before but I can't remember because I need to sleep...