I have a string that uses parts of another String, how to make this code "cleaner"? Since it is very difficult to understand.
String sessionHash = dirPath.substring(dirPath.substring(0, dirPath.length() - 1).lastIndexOf("/"));
sessionHash: / 23980dc32e16792007de3343f1f99211 /
dirPath: / home / daniela / oknok / data / uploads / 23980dc32e16792007de3343f1f99211 /